diff options
author | Brian Coca <bcoca@users.noreply.github.com> | 2019-04-04 15:59:52 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-04-04 15:59:52 +0200 |
commit | bda541fa0d2645dfd9efb7209c6b92e497588fe0 (patch) | |
tree | 29c7ea63aed89aafc49f170cc2affaf780509a9c /test/integration/targets | |
parent | Correctly update tags when os_stack invokes update_stack (#53757) (diff) | |
download | ansible-bda541fa0d2645dfd9efb7209c6b92e497588fe0.tar.xz ansible-bda541fa0d2645dfd9efb7209c6b92e497588fe0.zip |
fix missing attribs with dirct module execution (#53875)
* fix missing attribs with dirct module execution
* also make remote tmp handling smarter
update tests
* set default if attrib does not exist
* add simple test
Diffstat (limited to 'test/integration/targets')
-rw-r--r-- | test/integration/targets/run_modules/aliases | 1 | ||||
-rw-r--r-- | test/integration/targets/run_modules/args.json | 1 | ||||
-rw-r--r-- | test/integration/targets/run_modules/library/test.py | 7 | ||||
-rwxr-xr-x | test/integration/targets/run_modules/runme.sh | 6 |
4 files changed, 15 insertions, 0 deletions
diff --git a/test/integration/targets/run_modules/aliases b/test/integration/targets/run_modules/aliases new file mode 100644 index 0000000000..b59832142f --- /dev/null +++ b/test/integration/targets/run_modules/aliases @@ -0,0 +1 @@ +shippable/posix/group3 diff --git a/test/integration/targets/run_modules/args.json b/test/integration/targets/run_modules/args.json new file mode 100644 index 0000000000..c3abc21a8f --- /dev/null +++ b/test/integration/targets/run_modules/args.json @@ -0,0 +1 @@ +{ "ANSIBLE_MODULE_ARGS": {} } diff --git a/test/integration/targets/run_modules/library/test.py b/test/integration/targets/run_modules/library/test.py new file mode 100644 index 0000000000..bbe3182c58 --- /dev/null +++ b/test/integration/targets/run_modules/library/test.py @@ -0,0 +1,7 @@ +#!/usr/bin/python + +from ansible.module_utils.basic import AnsibleModule + +module = AnsibleModule(argument_spec=dict()) + +module.exit_json(**{'tempdir': module._remote_tmp}) diff --git a/test/integration/targets/run_modules/runme.sh b/test/integration/targets/run_modules/runme.sh new file mode 100755 index 0000000000..34c245cbf6 --- /dev/null +++ b/test/integration/targets/run_modules/runme.sh @@ -0,0 +1,6 @@ +#!/usr/bin/env bash + +set -eux + +# test running module directly +python.py library/test.py args.json |