ios integration tests to network_cli (#33920)

* Preliminary steps

* Fix Python3 network_cli ios

* Add connection to debug strings

* Fix ios confirm prompt by way of optional newline

Also update ios_user delete tests
This commit is contained in:
Nathaniel Case 2017-12-20 09:03:29 -05:00 committed by GitHub
commit cb1b705218
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
56 changed files with 358 additions and 102 deletions

View file

@ -1,5 +1,5 @@
---
- debug: msg="START cli/all_facts.yaml"
- debug: msg="START cli/all_facts.yaml on connection={{ ansible_connection }}"
- name: test getting all facts
@ -7,6 +7,7 @@
gather_subset:
- all
authorize: yes
become: yes
register: result
@ -28,4 +29,4 @@
- "result.ansible_facts.ansible_net_memfree_mb > 1"
- "result.ansible_facts.ansible_net_memtotal_mb > 1"
- debug: msg="END cli/all_facts.yaml"
- debug: msg="END cli/all_facts.yaml on connection={{ ansible_connection }}"

View file

@ -1,10 +1,11 @@
---
- debug: msg="START cli/default_facts.yaml"
- debug: msg="START cli/default_facts.yaml on connection={{ ansible_connection }}"
- name: test getting default facts
ios_facts:
authorize: yes
become: yes
register: result
- assert:
@ -28,4 +29,4 @@
# ... and not present
- "result.ansible_facts.ansible_net_config is not defined" # config
- debug: msg="END cli/default.yaml"
- debug: msg="END cli/default.yaml on connection={{ ansible_connection }}"

View file

@ -1,5 +1,5 @@
---
- debug: msg="START cli/invalid_subset.yaml"
- debug: msg="START cli/invalid_subset.yaml on connection={{ ansible_connection }}"
- name: test invalid subset (foobar)
@ -7,6 +7,7 @@
gather_subset:
- "foobar"
authorize: yes
become: yes
register: result
ignore_errors: true
@ -30,6 +31,7 @@
- "!hardware"
- "hardware"
authorize: yes
become: yes
register: result
ignore_errors: true
@ -45,4 +47,4 @@
- debug: msg="END cli/invalid_subset.yaml"
- debug: msg="END cli/invalid_subset.yaml on connection={{ ansible_connection }}"

View file

@ -1,5 +1,5 @@
---
- debug: msg="START cli/not_hardware_facts.yaml"
- debug: msg="START cli/not_hardware_facts.yaml on connection={{ ansible_connection }}"
- name: test not hardware
@ -7,6 +7,7 @@
gather_subset:
- "!hardware"
authorize: yes
become: yes
register: result
- assert:
@ -27,4 +28,4 @@
# ... and not present
- "result.ansible_facts.ansible_net_filesystems is not defined"
- debug: msg="END cli/not_hardware_facts.yaml"
- debug: msg="END cli/not_hardware_facts.yaml on connection={{ ansible_connection }}"