mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-23 05:10:22 -07:00
Cleanup net integration test case for network modules (#34684)
* Remove platform agnostic net_* test cases. * Add minimal platform agnostic test cases to individual platform-specific test cases
This commit is contained in:
parent
2df6735dcf
commit
c53dcd1982
181 changed files with 1630 additions and 6246 deletions
|
@ -0,0 +1,43 @@
|
|||
---
|
||||
- debug: msg="START junos netconf/net_vrf.yaml on connection={{ ansible_connection }}"
|
||||
|
||||
# Add minimal testcase to check args are passed correctly to
|
||||
# implementation module and module run is successful.
|
||||
|
||||
- name: setup - remove vrf
|
||||
net_vrf:
|
||||
name: test-1
|
||||
state: absent
|
||||
provider: "{{ netconf }}"
|
||||
|
||||
- name: Configure vrf and its parameter using platform agnostic vrf module
|
||||
net_vrf:
|
||||
name: test-1
|
||||
description: test-vrf-1
|
||||
interfaces:
|
||||
- ge-0/0/6
|
||||
- ge-0/0/5
|
||||
rd: 3.3.3.3:10
|
||||
target: target:65513:111
|
||||
state: present
|
||||
provider: "{{ netconf }}"
|
||||
register: result
|
||||
|
||||
- assert:
|
||||
that:
|
||||
- "result.changed == true"
|
||||
- result.diff.prepared is search("\+ *test-1")
|
||||
- result.diff.prepared is search("\+ *description test-vrf-1")
|
||||
- result.diff.prepared is search("\+ *instance-type vrf")
|
||||
- result.diff.prepared is search("\+ *interface ge-0/0/5.0")
|
||||
- result.diff.prepared is search("\+ *interface ge-0/0/6.0")
|
||||
- result.diff.prepared is search("\+ *route-distinguisher 3.3.3.3:10")
|
||||
- result.diff.prepared is search("\+ *vrf-target target:65513:111")
|
||||
|
||||
- name: teardown - remove vrf
|
||||
net_vrf:
|
||||
name: test-1
|
||||
state: absent
|
||||
provider: "{{ netconf }}"
|
||||
|
||||
- debug: msg="START junos netconf/net_vrf.yaml on connection={{ ansible_connection }}"
|
Loading…
Add table
Add a link
Reference in a new issue