1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

Use eos_config for eos_user tests teardown (#26893)

Purge is not idempotent, so let's fix it with other change.
For teardown, it's better to use eos_config/eos_command.
This commit is contained in:
Ricardo Carrillo Cruz 2017-07-17 14:28:03 +02:00 committed by GitHub
parent baa9290d71
commit bd24c4ce9d

View file

@ -31,13 +31,9 @@
- 'result.commands == ["username test1 role network-operator", "username test2 role network-operator"]' - 'result.commands == ["username test1 role network-operator", "username test2 role network-operator"]'
- name: tearDown - name: tearDown
eos_user: eos_config:
purge: yes lines:
authorize: yes - no username netend
- no username test1
- no username test2
provider: "{{ cli }}" provider: "{{ cli }}"
register: result
- assert:
that:
- 'result.changed == true'
- 'result.commands == ["no username netend", "no username test1", "no username test2"]'