summaryrefslogtreecommitdiffstats
path: root/test/integration/targets/test_infra
diff options
context:
space:
mode:
authorZhikang Zhang <zzhang63@ncsu.edu>2018-06-01 21:02:56 +0200
committerToshio Kuratomi <a.badger@gmail.com>2018-06-01 21:02:56 +0200
commitb578bf9e20f469272de1f8a1c21b58f27707cd32 (patch)
tree7abd3ae00eaee37f65459c665b8fa38d18a337b8 /test/integration/targets/test_infra
parentDo not try to import simplejson in jsonfile.py (#40983) (diff)
downloadansible-b578bf9e20f469272de1f8a1c21b58f27707cd32.tar.xz
ansible-b578bf9e20f469272de1f8a1c21b58f27707cd32.zip
Fix test-module failing to validate args (#41004)
* Fix test-module failing to validate args The test-module pass a wrong argument _ansible_tmp cause the validation failed. Change the argument _ansible_tmp to _ansible_tmpdir to fix this. * Add a integration test for test-module. Prior to this change, we don't have a test for test-module. This change ensure the correctness of test-module script.
Diffstat (limited to 'test/integration/targets/test_infra')
-rwxr-xr-xtest/integration/targets/test_infra/runme.sh4
1 files changed, 4 insertions, 0 deletions
diff --git a/test/integration/targets/test_infra/runme.sh b/test/integration/targets/test_infra/runme.sh
index a0951ad2b5..be3809f95b 100755
--- a/test/integration/targets/test_infra/runme.sh
+++ b/test/integration/targets/test_infra/runme.sh
@@ -21,3 +21,7 @@ echo "rc was $APB_RC (must be non-zero)"
echo "ensure playbook output shows assert/fail works (True)"
echo "$PB_OUT" | grep -F "fail works (True)" || exit 1
echo "$PB_OUT" | grep -F "assert works (True)" || exit 1
+
+# ensure test-module script works well
+PING_MODULE_PATH="$(pwd)/../../../../lib/ansible/modules/system/ping.py"
+../../../../hacking/test-module -m "$PING_MODULE_PATH" -I ansible_python_interpreter="$(which python)"