mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-22 04:40:22 -07:00
Fix cosmetic problems in YAML source
This change corrects problems reported by the `yamllint` linter.
Since key duplication problems were removed in 4d48711
, this commit
mainly fixes trailing spaces and extra empty lines at beginning/end of
files.
This commit is contained in:
parent
8874c1dc39
commit
0e834fc9e4
251 changed files with 214 additions and 510 deletions
|
@ -1,2 +1,2 @@
|
|||
- name: echoing handler
|
||||
command: echo CALLED_HANDLER_{{ inventory_hostname }}
|
||||
command: echo CALLED_HANDLER_{{ inventory_hostname }}
|
||||
|
|
|
@ -21,6 +21,6 @@
|
|||
- name: EXPECTED FAILURE fail task for C
|
||||
fail: msg="Fail C"
|
||||
when: inventory_hostname == 'C'
|
||||
|
||||
|
||||
- name: echo after A and C have failed
|
||||
command: echo CALLED_TASK_{{ inventory_hostname }}
|
||||
command: echo CALLED_TASK_{{ inventory_hostname }}
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
- name: set handler fact
|
||||
set_fact:
|
||||
set_fact:
|
||||
handler_called: True
|
||||
- name: test handler
|
||||
debug: msg="handler called"
|
||||
|
|
|
@ -1,2 +1 @@
|
|||
dependencies: []
|
||||
|
||||
|
|
|
@ -24,7 +24,7 @@
|
|||
|
||||
- name: notify the handler for host A only
|
||||
shell: echo
|
||||
notify:
|
||||
notify:
|
||||
- set handler fact
|
||||
when: inventory_hostname == 'A'
|
||||
tags: scenario1
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
- name: set_handler_fact_1
|
||||
set_fact:
|
||||
set_fact:
|
||||
handler1_called: True
|
||||
|
||||
- name: set_handler_fact_2
|
||||
|
|
|
@ -18,13 +18,13 @@
|
|||
|
||||
- name: notify the first handler
|
||||
shell: echo
|
||||
notify:
|
||||
notify:
|
||||
- set_handler_fact_1
|
||||
|
||||
- name: force handler execution now
|
||||
meta: "flush_handlers"
|
||||
|
||||
- name: assert handler1 ran and not handler2
|
||||
- name: assert handler1 ran and not handler2
|
||||
assert:
|
||||
that:
|
||||
- "handler1_called is defined"
|
||||
|
@ -36,6 +36,5 @@
|
|||
|
||||
- name: notify the second handler
|
||||
shell: echo
|
||||
notify:
|
||||
notify:
|
||||
- set_handler_fact_2
|
||||
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
connection: local
|
||||
tasks:
|
||||
- name: verify handler2 ran
|
||||
assert:
|
||||
assert:
|
||||
that:
|
||||
- "not hostvars[inventory_hostname]['handler1_called']"
|
||||
- "'handler2_called' in hostvars[inventory_hostname]"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue