summaryrefslogtreecommitdiffstats
path: root/test/integration/targets/lookup_items/tasks/main.yml
blob: 15a2cf2196ff4633a616cd10198058fd800b396c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
- name: test with_items
  set_fact: "{{ item }}=moo"
  with_items:
    - 'foo'
    - 'bar'

- name: Undefined var, skipped
  debug:
  with_items:
    - '{{ baz }}'
  when: false

- debug: var=foo
- debug: var=bar

- name: verify with_items results
  assert:
    that:
        - "foo == 'moo'"
        - "bar == 'moo'"