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.
35 lines
653 B
YAML
35 lines
653 B
YAML
8 years ago
|
---
|
||
7 years ago
|
- debug: msg="START cli/nxos_banner no-motd test"
|
||
|
|
||
8 years ago
|
- name: Setup
|
||
|
nxos_banner:
|
||
7 years ago
|
banner: motd
|
||
8 years ago
|
text: |
|
||
7 years ago
|
Junk motd banner
|
||
8 years ago
|
over multiple lines
|
||
|
state: present
|
||
7 years ago
|
provider: "{{ cli }}"
|
||
8 years ago
|
|
||
7 years ago
|
- name: remove motd
|
||
|
nxos_banner: &rm-motd
|
||
|
banner: motd
|
||
8 years ago
|
state: absent
|
||
7 years ago
|
provider: "{{ cli }}"
|
||
8 years ago
|
register: result
|
||
|
|
||
|
- assert:
|
||
|
that:
|
||
|
- "result.changed == true"
|
||
7 years ago
|
- "'no banner motd' in result.commands"
|
||
8 years ago
|
|
||
7 years ago
|
- name: remove motd (idempotent)
|
||
|
nxos_banner: *rm-motd
|
||
8 years ago
|
register: result
|
||
|
|
||
|
- assert:
|
||
|
that:
|
||
|
- "result.changed == false"
|
||
|
- "result.commands | length == 0"
|
||
|
|
||
7 years ago
|
- debug: msg="END cli/nxos_banner no-motd test"
|