ansible/test/integration/targets/iosxr_acls/tests/cli/rendered.yaml
Nilashish Chakraborty b818436c5f
Add iosxr_acls RM (#66207)
Signed-off-by: NilashishC <nilashishchakraborty8@gmail.com>
2020-02-24 18:34:27 +05:30

93 lines
2.6 KiB
YAML

---
- debug:
msg: "START iosxr_acls rendered integration tests on connection={{ ansible_connection }}"
- name: Render platform specific commands from task input using rendered state
iosxr_acls:
config:
- afi: ipv6
acls:
- name: acl6_1
aces:
- sequence: 10
grant: deny
protocol: tcp
source:
prefix: 2001:db8:1234::/48
port_protocol:
range:
start: ftp
end: telnet
destination:
any: True
protocol_options:
tcp:
syn: True
ttl:
range:
start: 180
end: 250
routing: True
authen: True
log: True
- sequence: 20
grant: permit
protocol: icmpv6
source:
any: True
destination:
any: True
protocol_options:
icmpv6:
router_advertisement: True
precedence: network
destopts: True
- afi: ipv4
acls:
- name: acl_1
aces:
- sequence: 16
remark: TEST_ACL_1_REMARK
- sequence: 21
grant: permit
protocol: tcp
source:
host: 192.0.2.10
port_protocol:
range:
start: pop3
end: 121
destination:
address: 198.51.100.0
wildcard_bits: 0.0.0.15
protocol_options:
tcp:
rst: True
- sequence: 23
grant: deny
protocol: icmp
source:
any: True
destination:
prefix: 198.51.100.0/28
protocol_options:
icmp:
reassembly_timeout: True
dscp:
lt: af12
- name: acl_2
aces:
- sequence: 10
remark: TEST_ACL_2_REMARK
state: rendered
register: result
- name: Assert that correct set of commands were rendered
assert:
that:
- "{{ merged['commands'] | symmetric_difference(result['rendered']) |length == 0 }}"