mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-22 04:40:22 -07:00
IOS-XR NetConf and Cliconf plugin work (#33332)
* - Netconf plugin addition for iosxr - Utilities refactoring to support netconf and cliconf - iosx_banner refactoring for netconf and cliconf - Integration testcases changes to accomodate above changes * Fix sanity failures, shippable errors and review comments * fix pep8 issue * changes run_command method to send specific command args * - Review comment fixes - iosxr_command changes to remove ComplexDict based command_spec * - Move namespaces removal method from utils to netconf plugin * Minor refactoring in utils and change in deprecation message * rewrite build_xml logic and import changes for new utils dir structure * - Review comment changes and minor changes to documentation * * refactor common code and docs updates
This commit is contained in:
parent
4b6061ce3e
commit
2bc4c4f156
42 changed files with 1090 additions and 247 deletions
|
@ -5,6 +5,7 @@
|
|||
name: auth_user
|
||||
state: present
|
||||
configured_password: pass123
|
||||
provider: "{{ cli }}"
|
||||
|
||||
- name: test login
|
||||
expect:
|
||||
|
@ -30,6 +31,7 @@
|
|||
name: auth_user
|
||||
state: present
|
||||
public_key_contents: "{{ lookup('file', \"{{ role_path }}/files/public.pub\") }}"
|
||||
provider: "{{ cli }}"
|
||||
|
||||
- name: test login with private key
|
||||
expect:
|
||||
|
@ -40,6 +42,7 @@
|
|||
- name: remove user and key
|
||||
iosxr_user:
|
||||
name: auth_user
|
||||
provider: "{{ cli }}"
|
||||
state: absent
|
||||
|
||||
- name: test login with private key (should fail, no user)
|
||||
|
@ -55,6 +58,7 @@
|
|||
name: auth_user
|
||||
state: present
|
||||
public_key: "{{ role_path }}/files/public.pub"
|
||||
provider: "{{ cli }}"
|
||||
|
||||
- name: test login with private key
|
||||
expect:
|
||||
|
@ -68,6 +72,7 @@
|
|||
name: auth_user
|
||||
state: present
|
||||
public_key_contents: "{{ lookup('file', \"{{ role_path }}/files/public2.pub\") }}"
|
||||
provider: "{{ cli }}"
|
||||
|
||||
# FIXME: pexpect fails with OSError: [Errno 5] Input/output error
|
||||
- name: test login with invalid private key (should fail)
|
||||
|
@ -88,4 +93,5 @@
|
|||
iosxr_user:
|
||||
name: auth_user
|
||||
state: absent
|
||||
provider: "{{ cli }}"
|
||||
register: result
|
||||
|
|
|
@ -5,12 +5,14 @@
|
|||
- no username ansibletest1
|
||||
- no username ansibletest2
|
||||
- no username ansibletest3
|
||||
provider: "{{ cli }}"
|
||||
|
||||
- name: Create user (SetUp)
|
||||
iosxr_user:
|
||||
name: ansibletest1
|
||||
configured_password: test
|
||||
state: present
|
||||
provider: "{{ cli }}"
|
||||
register: result
|
||||
|
||||
- assert:
|
||||
|
@ -25,6 +27,7 @@
|
|||
configured_password: test
|
||||
update_password: always
|
||||
state: present
|
||||
provider: "{{ cli }}"
|
||||
register: result
|
||||
|
||||
- assert:
|
||||
|
@ -39,6 +42,7 @@
|
|||
configured_password: test
|
||||
update_password: on_create
|
||||
state: present
|
||||
provider: "{{ cli }}"
|
||||
register: result
|
||||
|
||||
- assert:
|
||||
|
@ -53,6 +57,7 @@
|
|||
update_password: on_create
|
||||
group: sysadmin
|
||||
state: present
|
||||
provider: "{{ cli }}"
|
||||
register: result
|
||||
|
||||
- assert:
|
||||
|
@ -68,6 +73,7 @@
|
|||
update_password: on_create
|
||||
group: sysadmin
|
||||
state: present
|
||||
provider: "{{ cli }}"
|
||||
register: result
|
||||
|
||||
- assert:
|
||||
|
@ -83,6 +89,7 @@
|
|||
configured_password: test
|
||||
state: present
|
||||
group: sysadmin
|
||||
provider: "{{ cli }}"
|
||||
register: result
|
||||
|
||||
- assert:
|
||||
|
@ -103,6 +110,7 @@
|
|||
configured_password: test
|
||||
state: present
|
||||
group: sysadmin
|
||||
provider: "{{ cli }}"
|
||||
register: result
|
||||
|
||||
- assert:
|
||||
|
@ -122,6 +130,7 @@
|
|||
update_password: on_create
|
||||
state: present
|
||||
group: sysadmin
|
||||
provider: "{{ cli }}"
|
||||
register: result
|
||||
|
||||
- assert:
|
||||
|
@ -136,6 +145,7 @@
|
|||
- name: ansibletest2
|
||||
- name: ansibletest3
|
||||
state: absent
|
||||
provider: "{{ cli }}"
|
||||
register: result
|
||||
|
||||
- assert:
|
||||
|
@ -150,6 +160,7 @@
|
|||
- name: ansibletest2
|
||||
- name: ansibletest3
|
||||
state: absent
|
||||
provider: "{{ cli }}"
|
||||
register: result
|
||||
|
||||
- assert:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue