Debian Codegraph @

test/integration/targets/includes/include_role_missing.yml

raw
1 - hosts: localhost
2 gather_facts: no
3 tasks:
4 - file:
5 path: roles/rolename
6 state: "{{ item }}"
7 loop:
8 - absent
9 - directory
10
11 - name: ensure we fail when missing both file and tasks/ subdir
12 block:
13 - include_role:
14 name: rolename
15 tasks_from: missing.yml
16 rescue:
17 - set_fact:
18 wefailed: True
19 always:
20 - name: check we actually failed
21 assert:
22 that:
23 - wefailed is defined
24 - wefailed