01e4c41be4
* nxos_integration_tests: Removing obsolete provider parameter * nxos: removing support for local-nxapi plugin * nxos: removing LocalNxapi plugin implementation * nxos_nxapi: removing local plugin usage * REVERT - nxos: removing LocalNxapi plugin implementation * Addressing yamllint issues * Removing the condition on the debug messages * Restoring changes done to nxos_nxapi* tests * Retaining timeout of 500 on nxos_smoke test * Some cleanup * Addressing latest comments * Restoring the nxos_smoke and removing timeout from nxos_config and nxos_rollback
58 lines
1.6 KiB
YAML
58 lines
1.6 KiB
YAML
---
|
|
- debug: msg="START nxapi/sublevel_strict.yaml"
|
|
|
|
- name: setup
|
|
nxos_config:
|
|
lines:
|
|
- 10 permit ip 192.0.2.1/32 any log
|
|
- 20 permit ip 192.0.2.2/32 any log
|
|
- 30 permit ip 192.0.2.3/32 any log
|
|
- 40 permit ip 192.0.2.4/32 any log
|
|
- 50 permit ip 192.0.2.5/32 any log
|
|
parents: ip access-list test
|
|
match: none
|
|
|
|
- name: configure sub level command using strict match
|
|
nxos_config:
|
|
lines:
|
|
- 10 permit ip 192.0.2.1/32 any log
|
|
- 30 permit ip 192.0.2.2/32 any log
|
|
- 20 permit ip 192.0.2.3/32 any log
|
|
- 40 permit ip 192.0.2.4/32 any log
|
|
parents: ip access-list test
|
|
before: no ip access-list test
|
|
match: strict
|
|
replace: block
|
|
register: result
|
|
|
|
- assert:
|
|
that:
|
|
- "result.changed == true"
|
|
- "'ip access-list test' in result.updates"
|
|
- "'10 permit ip 192.0.2.1/32 any log' in result.updates"
|
|
- "'30 permit ip 192.0.2.2/32 any log' in result.updates"
|
|
- "'20 permit ip 192.0.2.3/32 any log' in result.updates"
|
|
- "'40 permit ip 192.0.2.4/32 any log' in result.updates"
|
|
- "'50 permit ip 192.0.2.5/32 any log' not in result.updates"
|
|
|
|
- name: check sub level command using strict match
|
|
nxos_config:
|
|
lines:
|
|
- 10 permit ip 192.0.2.1/32 any log
|
|
- 20 permit ip 192.0.2.3/32 any log
|
|
- 30 permit ip 192.0.2.2/32 any log
|
|
- 40 permit ip 192.0.2.4/32 any log
|
|
parents: ip access-list test
|
|
match: strict
|
|
register: result
|
|
|
|
- assert:
|
|
that:
|
|
- "result.changed == false"
|
|
|
|
- name: teardown
|
|
nxos_config:
|
|
lines: no ip access-list test
|
|
match: none
|
|
|
|
- debug: msg="END nxapi/sublevel_strict.yaml"
|