ansible/test/integration/targets/set_fact/incremental.yml
Felix Fontein 27f547b4d3
[2.10] Fix missing ansible.builtin FQCNs in hardcoded action names (#72457)
* Fix missing ansible.builtin FQCNs in hardcoded action names (#71824)

* Make sure hard-coded action names also check for FQCN.
* Use _add_internal_fqcn() to avoid hardcoded lists and typoes.

(cherry picked from commit da60525610)

* Replace some more FQCNs.

(cherry picked from commit 72302dd611)
2020-12-07 16:59:12 -06:00

35 lines
869 B
YAML

- name: test set_fact incremental https://github.com/ansible/ansible/issues/38271
hosts: testhost
gather_facts: no
tasks:
- name: Generate inline loop for set_fact
set_fact:
dig_list: "{{ dig_list + [ item ] }}"
loop:
- two
- three
- four
vars:
dig_list:
- one
- name: verify cumulative set fact worked
assert:
that:
- dig_list == ['one', 'two', 'three', 'four']
- name: Generate inline loop for set_fact (FQCN)
ansible.builtin.set_fact:
dig_list_fqcn: "{{ dig_list_fqcn + [ item ] }}"
loop:
- two
- three
- four
vars:
dig_list_fqcn:
- one
- name: verify cumulative set fact worked (FQCN)
assert:
that:
- dig_list_fqcn == ['one', 'two', 'three', 'four']