mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-06 21:32:49 +00:00
Use loop_control.loop_var directly
6eefc11c converted task.loop_control into an object, but while the other
callers were updated to use .loop_var instead of .get('loop_var'), this
site was overlooked.
This can be reproduced by including with loop_control a file that does
set_fact; a simple regression test along these lines is included.
This commit is contained in:
@@ -1 +1,3 @@
|
||||
- include: test_includes2.yml parameter1=asdf parameter2=jkl
|
||||
|
||||
- include: test_includes3.yml
|
||||
|
||||
7
test/integration/test_includes3.yml
Normal file
7
test/integration/test_includes3.yml
Normal file
@@ -0,0 +1,7 @@
|
||||
---
|
||||
- hosts: localhost
|
||||
tasks:
|
||||
- include: test_includes4.yml
|
||||
with_items: ["a"]
|
||||
loop_control:
|
||||
loop_var: r
|
||||
2
test/integration/test_includes4.yml
Normal file
2
test/integration/test_includes4.yml
Normal file
@@ -0,0 +1,2 @@
|
||||
- set_fact:
|
||||
p: 1
|
||||
Reference in New Issue
Block a user