CSIT-1459: Migrate IP libraries from VAT to PAPI
[csit.git] / tests / vpp / func / ip6 / eth2p-ethip6-ip6base-ip6ra-func.robot
1 # Copyright (c) 2019 Cisco and/or its affiliates.
2 # Licensed under the Apache License, Version 2.0 (the "License");
3 # you may not use this file except in compliance with the License.
4 # You may obtain a copy of the License at:
5 #
6 #     http://www.apache.org/licenses/LICENSE-2.0
7 #
8 # Unless required by applicable law or agreed to in writing, software
9 # distributed under the License is distributed on an "AS IS" BASIS,
10 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11 # See the License for the specific language governing permissions and
12 # limitations under the License.
13
14 *** Settings ***
15 | Library | resources.libraries.python.Trace
16 | ...
17 | Resource | resources/libraries/robot/ip/ip6.robot
18 | Resource | resources/libraries/robot/shared/counters.robot
19 | Resource | resources/libraries/robot/shared/default.robot
20 | Resource | resources/libraries/robot/shared/interfaces.robot
21 | Resource | resources/libraries/robot/shared/testing_path.robot
22 | Resource | resources/libraries/robot/shared/traffic.robot
23 | ...
24 | Force Tags | HW_ENV | VM_ENV | 3_NODE_SINGLE_LINK_TOPO | SKIP_VPP_PATCH
25 | ...
26 | Test Setup | Set up functional test
27 | ...
28 | Test Teardown | Tear down functional test
29 | ...
30 | Documentation | *IPv6 Router Advertisement test cases*
31 | ...
32 | ... | RFC4861 Neighbor Discovery. Encapsulations: Eth-IPv6-RA on links
33 | ... | TG-DUT1. IPv6 Router Advertisement tests use 3-node topology TG - DUT1 -
34 | ... | DUT2 - TG with one link between the nodes. DUT1 and DUT2 are configured
35 | ... | with IPv6 routing and static routes. TG verifies received RA packets.
36
37
38 *** Variables ***
39 | ${dut1_to_tg_ip}= | 3ffe:62::1
40 | ${tg_to_dut1_ip}= | 3ffe:62::2
41 | ${prefix_length}= | 64
42 | ${interval}= | 2
43
44 *** Test Cases ***
45 | TC01: DUT transmits RA on IPv6 enabled interface
46 | | [Documentation]
47 | | ... | [Top] TG-DUT1-DUT2-TG.
48 | | ... | [Cfg] On DUT1 configure IPv6 interface on the link to TG.
49 | | ... | [Ver] Make TG wait for IPv6 Router Advertisement packet to be sent\
50 | | ... | by DUT1 and verify the received RA packet is correct.
51 | | [Tags] | EXPECTED_FAILING
52 | | Given Configure path in 3-node circular topology
53 | | ... | ${nodes['TG']} | ${nodes['DUT1']} | ${nodes['DUT2']} | ${nodes['TG']}
54 | | And Set interfaces in 3-node circular topology up
55 | | And VPP Interface Set IP Address | ${dut1_node}
56 | | ... | ${dut1_to_tg} | ${dut1_to_tg_ip} | ${prefix_length}
57 | | When Vpp RA Send After Interval | ${dut1_node} | ${dut1_to_tg}
58 | | Then Receive and verify router advertisement packet
59 | | ... | ${tg_node} | ${tg_to_dut1} | ${dut1_to_tg_mac}
60
61 | TC02: DUT retransmits RA on IPv6 enabled interface after a set interval
62 | | [Documentation]
63 | | ... | [Top] TG-DUT1-DUT2-TG.
64 | | ... | [Cfg] On DUT1 configure IPv6 interface on the link to TG.
65 | | ... | [Ver] Make TG wait for two IPv6 Router Advertisement packets\
66 | | ... | to be sent by DUT1 and verify the received RA packets are correct.
67 | | [Tags] | EXPECTED_FAILING
68 | | Given Configure path in 3-node circular topology
69 | | ... | ${nodes['TG']} | ${nodes['DUT1']} | ${nodes['DUT2']} | ${nodes['TG']}
70 | | And Set interfaces in 3-node circular topology up
71 | | And VPP Interface Set IP Address
72 | | ... | ${dut1_node} | ${dut1_to_tg} | ${dut1_to_tg_ip} | ${prefix_length}
73 | | When Vpp RA Send After Interval | ${dut1_node} | ${dut1_to_tg}
74 | | ... | interval=${interval}
75 | | :FOR | ${n} | IN RANGE | ${2}
76 | | | Then Receive and verify router advertisement packet
77 | | | ... | ${tg_node} | ${tg_to_dut1} | ${dut1_to_tg_mac} | ${interval}
78
79 | TC03: DUT responds to Router Solicitation request
80 | | [Documentation]
81 | | ... | [Top] TG-DUT1-DUT2-TG.
82 | | ... | [Cfg] On DUT1 configure IPv6 interface on the link to TG and suppress\
83 | | ... | sending of Router Advertisement packets periodically.
84 | | ... | [Ver] Make TG send IPv6 Router Solicitation request to DUT1, listen\
85 | | ... | for response from DUT1 and verify the received RA packet is correct.
86 | | [Tags] | EXPECTED_FAILING
87 | | Given Configure path in 3-node circular topology
88 | | ... | ${nodes['TG']} | ${nodes['DUT1']} | ${nodes['DUT2']} | ${nodes['TG']}
89 | | And Set interfaces in 3-node circular topology up
90 | | And VPP Interface Set IP Address
91 | | ... | ${dut1_node} | ${dut1_to_tg} | ${dut1_to_tg_ip} | ${prefix_length}
92 | | When VPP RA Suppress Link Layer | ${dut1_node} | ${dut1_to_tg}
93 | | Then Send router solicitation and verify response
94 | | ... | ${tg_node} | ${dut1_node} | ${tg_to_dut1} | ${dut1_to_tg}
95 | | ... | ${tg_to_dut1_ip}
96
97 | TC04: DUT responds to Router Solicitation request sent from link local address
98 | | [Documentation]
99 | | ... | [Top] TG-DUT1-DUT2-TG.
100 | | ... | [Cfg] On DUT1 configure IPv6 interface on the link to TG and suppress\
101 | | ... | sending of Router Advertisement packets periodically.
102 | | ... | [Ver] Make TG send IPv6 Router Solicitation request to DUT1, listen\
103 | | ... | for response from DUT1 and verify the received RA packet is correct.
104 | | [Tags] | EXPECTED_FAILING
105 | | Given Configure path in 3-node circular topology
106 | | ... | ${nodes['TG']} | ${nodes['DUT1']} | ${nodes['DUT2']} | ${nodes['TG']}
107 | | And Set interfaces in 3-node circular topology up
108 | | And VPP Interface Set IP Address
109 | | ... | ${dut1_node} | ${dut1_to_tg} | ${dut1_to_tg_ip} | ${prefix_length}
110 | | When VPP RA Suppress Link Layer | ${dut1_node} | ${dut1_to_tg}
111 | | Then Send router solicitation and verify response
112 | | ... | ${tg_node} | ${dut1_node} | ${tg_to_dut1} | ${dut1_to_tg}