diff options
author | Rick Elrod <rick@elrod.me> | 2020-08-03 17:30:45 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-08-03 17:30:45 +0200 |
commit | 74c14c67439ff2d5e24dfb142c7fadf701fb6712 (patch) | |
tree | 700e6684d538d7eb3a689dc3cf6acc65351658fb /test/integration | |
parent | Document string tests a bit more (#71049) (diff) | |
download | ansible-74c14c67439ff2d5e24dfb142c7fadf701fb6712.tar.xz ansible-74c14c67439ff2d5e24dfb142c7fadf701fb6712.zip |
Strip spaces in module names in explicit actions (#71040)
* Strip spaces in module names in explicit actions
Change:
- When an action is called like "action: copy foo=bar", strip spaces
around the action name.
- This allows "action: copy foo=bar" to work as expected.
Test Plan:
- New integration tests
Tickets:
- Fixes #62136
Signed-off-by: Rick Elrod <rick@elrod.me>
Diffstat (limited to 'test/integration')
-rw-r--r-- | test/integration/targets/parsing/roles/test_good_parsing/tasks/main.yml | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/test/integration/targets/parsing/roles/test_good_parsing/tasks/main.yml b/test/integration/targets/parsing/roles/test_good_parsing/tasks/main.yml index 0fb1337e86..d225c0f9f9 100644 --- a/test/integration/targets/parsing/roles/test_good_parsing/tasks/main.yml +++ b/test/integration/targets/parsing/roles/test_good_parsing/tasks/main.yml @@ -202,3 +202,16 @@ - should_not_omit_1 is defined - should_not_omit_2 is defined - should_not_omit_3 == "__omit_place_holder__afb6b9bc3d20bfeaa00a1b23a5930f89" + +- name: Ensure module names are stripped of extra spaces (local_action) + local_action: set_fact b="b" + register: la_set_fact_b + +- name: Ensure module names are stripped of extra spaces (action) + action: set_fact c="c" + register: la_set_fact_c + +- assert: + that: + - b == "b" + - c == "c" |