mirror of https://github.com/ansible/ansible.git
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
42 lines
1.0 KiB
YAML
42 lines
1.0 KiB
YAML
- name: rune one and two, verify merge is as expected
|
|
hosts: localhost
|
|
vars:
|
|
ansible_facts_modules:
|
|
- facts_one
|
|
- facts_two
|
|
tasks:
|
|
|
|
- name: populate original
|
|
include_vars:
|
|
name: original
|
|
file: one_two.json
|
|
|
|
- name: fail if ref file is updated
|
|
assert:
|
|
msg: '{{ansible_facts}} vs {{original}}'
|
|
that:
|
|
- ansible_facts|to_json(indent=4, sort_keys=True) == original|to_json(indent=4, sort_keys=True)
|
|
|
|
- name: clear existing facts for next play
|
|
meta: clear_facts
|
|
|
|
|
|
- name: rune two and one, verify merge is as expected
|
|
hosts: localhost
|
|
vars:
|
|
ansible_facts_modules:
|
|
- facts_two
|
|
- facts_one
|
|
tasks:
|
|
|
|
- name: populate original
|
|
include_vars:
|
|
name: original
|
|
file: two_one.json
|
|
|
|
- name: fail if ref file is updated
|
|
assert:
|
|
msg: '{{ansible_facts}} vs {{original}}'
|
|
that:
|
|
- ansible_facts|to_json(indent=4, sort_keys=True) == original|to_json(indent=4, sort_keys=True)
|