Debian Codegraph @

test/integration/targets/blocks/72725.yml

raw
1 - hosts: host1,host2
2 gather_facts: no
3 tasks:
4 - block:
5 - block:
6 - name: EXPECTED FAILURE host1 fails
7 fail:
8 when: inventory_hostname == 'host1'
9
10 - set_fact:
11 only_host2_fact: yes
12
13 - name: should not fail
14 fail:
15 when: only_host2_fact is not defined
16 always:
17 - block:
18 - meta: clear_host_errors
19
20 - assert:
21 that:
22 - only_host2_fact is defined
23 when:
24 - inventory_hostname == 'host2'