mirror of https://github.com/ansible/ansible.git
ensure assert and fail work before we test anything else
parent
9318727021
commit
6c835b2600
@ -0,0 +1,21 @@
|
||||
- hosts: testhost
|
||||
gather_facts: no
|
||||
tasks:
|
||||
- fail:
|
||||
ignore_errors: yes
|
||||
register: fail_out
|
||||
|
||||
- debug:
|
||||
msg: fail works ({{ fail_out.failed }})
|
||||
|
||||
- assert:
|
||||
that: false
|
||||
ignore_errors: yes
|
||||
register: assert_out
|
||||
|
||||
- debug:
|
||||
msg: assert works ({{ assert_out.failed }})
|
||||
|
||||
- fail:
|
||||
msg: fail actually failed
|
||||
|
Loading…
Reference in New Issue