HC Tests: mark VRF assignment tests as failing (HC2VPP-331)
[csit.git] / tests / honeycomb / func / mgmt-cfg-routing-apihc-apivat-func.robot
1 # Copyright (c) 2017 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.honeycomb.Routing.RoutingKeywords
16 | Library | resources.libraries.python.Trace
17 | Resource | resources/libraries/robot/shared/default.robot
18 | Resource | resources/libraries/robot/shared/testing_path.robot
19 | Resource | resources/libraries/robot/ip/ip4.robot
20 | Resource | resources/libraries/robot/ip/ip6.robot
21 | Resource | resources/libraries/robot/honeycomb/honeycomb.robot
22 | Resource | resources/libraries/robot/honeycomb/interfaces.robot
23 | Resource | resources/libraries/robot/honeycomb/routing.robot
24 | ...
25 | Test Setup | Clear Packet Trace on All DUTs | ${nodes}
26 | ...
27 | Suite Setup | Set Up Honeycomb Functional Test Suite | ${node}
28 | ...
29 | Suite Teardown | Tear Down Honeycomb Functional Test Suite | ${node}
30 | ...
31 | Test Teardown | Honeycomb routing test teardown | ${node} | ${table}
32 | ...
33 | Documentation | *Honeycomb routing test suite.*
34 | ...
35 | Force Tags | HC_FUNC
36
37 *** Test Cases ***
38 | TC01: Single hop IPv4 route
39 | | [Documentation]
40 | | ... | [Top] TG=DUT1=TG.
41 | | ... | [Enc] Eth-IPv4-ICMP.
42 | | ... | [Cfg] (Using Honeycomb API) On DUT1 add ARP entries to both TG\
43 | | ... | interfaces and configure route with TG-if2 as next-hop.
44 | | ... | [Ver] Send ICMP packet from first TG interface to configured route
45 | | ... | destination. Receive packet on the second TG interface.
46 | | ...
47 # HC2VPP-331: Honeycomb fails to assign VRF to interface
48 | | [Tags] | EXPECTED_FAILING
49 | | ...
50 | | ${table}= | Set Variable | table1
51 | | Given Setup interfaces and neighbors for IPv4 routing test
52 | | When Honeycomb configures routing table
53 | | ... | ${node} | table1 | ipv4 | ${table1} | ${1}
54 | | Then Routing data from Honeycomb should contain
55 | | ... | ${node} | table1 | ipv4 | ${table1_oper}
56 | | And Verify route IPv4 | ${nodes['TG']}
57 | | ... | ${src_ip} | ${dst_ip}
58 | | ... | ${tg_to_dut_if1} | ${tg_to_dut_if1_mac}
59 | | ... | ${tg_to_dut_if2} | ${dut_to_tg_if1_mac}
60
61 | TC02: Multi hop IPv4 route
62 | | [Documentation]
63 | | ... | [Top] TG=DUT1=TG.
64 | | ... | [Enc] Eth-IPv4-ICMP.
65 | | ... | [Cfg] (Using Honeycomb API) On DUT1 add ARP entries to both TG\
66 | | ... | interfaces and configure two routes through the second DUT interface.
67 | | ... | [Ver] Send 100 ICMP packets from first TG interface to configured
68 | | ... | route destination. Receive all packets on the second TG interface and\
69 | | ... | verify that each destination MAC was used by exactly 50 packets.
70 | | ... | Receive packet on the second TG interface.
71 | | ...
72 # HC2VPP-331: Honeycomb fails to assign VRF to interface
73 | | [Tags] | EXPECTED_FAILING
74 | | ...
75 | | ${table}= | Set Variable | table2
76 | | Given Setup interfaces and neighbors for IPv4 routing test
77 | | And Honeycomb adds interface IPv4 neighbor | ${dut_node} | ${dut_to_tg_if2}
78 | | ... | ${next_hop1} | ${next_hop_mac1}
79 | | And Honeycomb adds interface IPv4 neighbor | ${dut_node} | ${dut_to_tg_if2}
80 | | ... | ${next_hop2} | ${next_hop_mac2}
81 | | ...
82 # HC2VPP-331: Honeycomb fails to assign VRF to interface
83 | | [Tags] | EXPECTED_FAILING
84 | | ...
85 | | When Honeycomb configures routing table
86 | | ... | ${node} | table2 | ipv4 | ${table2} | ${1}
87 | | Then Routing data from Honeycomb should contain
88 | | ... | ${node} | table2 | ipv4 | ${table2_oper}
89 | | And Verify multipath Route | ${nodes['TG']}
90 | | ... | ${src_ip} | ${dst_ip}
91 | | ... | ${tg_to_dut_if1} | ${tg_to_dut_if1_mac}
92 | | ... | ${tg_to_dut_if2} | ${dut_to_tg_if1_mac}
93 | | ... | ${dut_to_tg_if2_mac} | ${next_hop_mac1} | ${next_hop_mac2}
94
95 | TC03: Special hop - blackhole IPv4 route
96 | | [Documentation]
97 | | ... | [Top] TG=DUT1=TG.
98 | | ... | [Enc] Eth-IPv4-ICMP.
99 | | ... | [Cfg] (Using Honeycomb API) On DUT1 add ARP entries to both TG\
100 | | ... | interfaces and configure route with special rule blackhole.
101 | | ... | [Ver] Send ICMP packet from first TG interface to configured route
102 | | ... | destination. Make sure no packet is received on the second TG\
103 | | ... | interface.
104 | | ...
105 # HC2VPP-331: Honeycomb fails to assign VRF to interface
106 | | [Tags] | EXPECTED_FAILING
107 | | ...
108 | | ${table}= | Set Variable | table3
109 | | Given Setup interfaces and neighbors for IPv4 routing test
110 | | When Honeycomb configures routing table
111 | | ... | ${node} | table3 | ipv4 | ${table3} | ${1} | special=${TRUE}
112 | | Then Routing data from Honeycomb should contain
113 | | ... | ${node} | table3 | ipv4 | ${table3_oper}
114 | | And Run keyword and Expect Error | ICMP echo Rx timeout
115 | | ... | Verify route IPv4 | ${nodes['TG']}
116 | | ... | ${src_ip} | ${dst_ip}
117 | | ... | ${tg_to_dut_if1} | ${tg_to_dut_if1_mac}
118 | | ... | ${tg_to_dut_if2} | ${dut_to_tg_if1_mac}
119
120 | TC04: Single hop IPv6 route
121 | | [Documentation]
122 | | ... | [Top] TG=DUT1=TG.
123 | | ... | [Enc] Eth-IPv6-ICMPv6.
124 | | ... | [Cfg] (Using Honeycomb API) On DUT1 add ARP entries to both TG\
125 | | ... | interfaces and configure route with TG-if2 as next-hop.
126 | | ... | [Ver] Send ICMP packet from first TG interface to configured route
127 | | ... | destination. Receive packet on the second TG interface.
128 | | ...
129 # HC2VPP-331: Honeycomb fails to assign VRF to interface
130 | | [Tags] | EXPECTED_FAILING
131 | | ...
132 | | ${table}= | Set Variable | table4
133 | | Given Setup interfaces and neighbors for IPv6 routing test
134 | | When Honeycomb configures routing table
135 | | ... | ${node} | table4 | ipv6 | ${table4} | ${1}
136 | | Then Routing data from Honeycomb should contain
137 | | ... | ${node} | table4 | ipv6 | ${table4_oper}
138 | | And Verify route IPv6 | ${nodes['TG']}
139 | | ... | ${src_ip} | ${next_hop}
140 | | ... | ${tg_to_dut_if1} | ${tg_to_dut_if1_mac}
141 | | ... | ${tg_to_dut_if2} | ${dut_to_tg_if1_mac}
142
143 | TC05: Multi hop IPv6 route
144 | | [Documentation]
145 | | ... | [Top] TG=DUT1=TG.
146 | | ... | [Enc] Eth-IPv6-ICMPv6.
147 | | ... | [Cfg] (Using Honeycomb API) On DUT1 add ARP entries to both TG\
148 | | ... | interfaces and configure two routes through the second DUT interface.
149 | | ... | [Ver] Send 100 ICMP packets from first TG interface to configured
150 | | ... | route destination. Receive all packets on the second TG interface and\
151 | | ... | verify that each destination MAC was used by exactly 50 packets.
152 | | ... | Receive packet on the second TG interface.
153 | | ...
154 # HC2VPP-331: Honeycomb fails to assign VRF to interface
155 | | [Tags] | EXPECTED_FAILING
156 | | ...
157 | | ${table}= | Set Variable | table5
158 | | Given Setup interfaces and neighbors for IPv6 routing test
159 | | And Honeycomb adds interface IPv6 neighbor | ${dut_node} | ${dut_to_tg_if2}
160 | | ... | ${next_hop1} | ${next_hop_mac1}
161 | | And Honeycomb adds interface IPv6 neighbor | ${dut_node} | ${dut_to_tg_if2}
162 | | ... | ${next_hop2} | ${next_hop_mac2}
163 | | When Honeycomb configures routing table
164 | | ... | ${node} | table5 | ipv6 | ${table5} | ${1}
165 | | Then Routing data from Honeycomb should contain
166 | | ... | ${node} | table5 | ipv6 | ${table5_oper}
167 | | And Verify multipath Route | ${nodes['TG']}
168 | | ... | ${src_ip} | ${dst_ip}
169 | | ... | ${tg_to_dut_if1} | ${tg_to_dut_if1_mac}
170 | | ... | ${tg_to_dut_if2} | ${dut_to_tg_if1_mac}
171 | | ... | ${dut_to_tg_if2_mac} | ${next_hop_mac1} | ${next_hop_mac2}
172
173 | TC06: Special hop - blackhole IPv6 route
174 | | [Documentation]
175 | | ... | [Top] TG=DUT1=TG.
176 | | ... | [Enc] Eth-IPv6-ICMPv6.
177 | | ... | [Cfg] (Using Honeycomb API) On DUT1 add ARP entries to both TG\
178 | | ... | interfaces and configure route with special rule blackhole.
179 | | ... | [Ver] Send ICMP packet from first TG interface to configured route
180 | | ... | destination. Make sure no packet is received on the second TG\
181 | | ... | interface.
182 | | ...
183 # HC2VPP-254 Operational data for Blackhole IPv6 route is incorrect
184 | | [Tags] | EXPECTED_FAILING
185 | | ${table}= | Set Variable | table6
186 | | Given Setup interfaces and neighbors for IPv6 routing test
187 | | When Honeycomb configures routing table
188 | | ... | ${node} | table6 | ipv6 | ${table6} | ${1} | special=${TRUE}
189 | | Then Routing data from Honeycomb should contain
190 | | ... | ${node} | table6 | ipv6 | ${table6_oper}
191 | | And Run keyword and Expect Error | ICMP echo Rx timeout
192 | | ... | Verify route IPv6 | ${nodes['TG']}
193 | | ... | ${src_ip} | ${dst_ip}
194 | | ... | ${tg_to_dut_if1} | ${tg_to_dut_if1_mac}
195 | | ... | ${tg_to_dut_if2} | ${dut_to_tg_if1_mac}
196
197 *** Keywords ***
198 | Setup interfaces and neighbors for IPv4 routing test
199 | | Configure path in 2-node circular topology
200 | | ... | ${nodes['TG']} | ${nodes['DUT1']} | ${nodes['TG']}
201 | | Import Variables | resources/test_data/honeycomb/routing.py
202 | | ... | ${nodes['DUT1']} | ipv4 | ${dut_to_tg_if2}
203 | | Setup vrf IDs | ${dut_node} | ${dut_to_tg_if1} | ${1}
204 | | Setup vrf IDs | ${dut_node} | ${dut_to_tg_if2} | ${1}
205 | | Honeycomb configures interface state | ${dut_node} | ${dut_to_tg_if1} | up
206 | | Honeycomb configures interface state | ${dut_node} | ${dut_to_tg_if2} | up
207 | | Honeycomb sets interface IPv4 address with prefix | ${dut_node}
208 | | ... | ${dut_to_tg_if1} | ${dut_to_tg_if1_ip} | ${prefix_len}
209 | | Honeycomb sets interface IPv4 address with prefix | ${dut_node}
210 | | ... | ${dut_to_tg_if2} | ${dut_to_tg_if2_ip} | ${prefix_len}
211 | | Honeycomb adds interface IPv4 neighbor | ${dut_node} | ${dut_to_tg_if1}
212 | | ... | ${src_ip} | ${tg_to_dut_if1_mac}
213 | | Honeycomb adds interface IPv4 neighbor | ${dut_node} | ${dut_to_tg_if2}
214 | | ... | ${next_hop} | ${tg_to_dut_if2_mac}
215
216 | Setup interfaces and neighbors for IPv6 routing test
217 | | Configure path in 2-node circular topology
218 | | ... | ${nodes['TG']} | ${nodes['DUT1']} | ${nodes['TG']}
219 | | Import Variables | resources/test_data/honeycomb/routing.py
220 | | ... | ${nodes['DUT1']} | ipv6 | ${dut_to_tg_if2}
221 | | Honeycomb sets interface VRF ID
222 | | ... | ${dut_node} | ${dut_to_tg_if1} | ${1} | ipv6
223 | | Honeycomb sets interface VRF ID
224 | | ... | ${dut_node} | ${dut_to_tg_if2} | ${1} | ipv6
225 | | Honeycomb configures interface state | ${dut_node} | ${dut_to_tg_if1} | up
226 | | Honeycomb configures interface state | ${dut_node} | ${dut_to_tg_if2} | up
227 | | Honeycomb sets interface IPv6 address | ${dut_node}
228 | | ... | ${dut_to_tg_if1} | ${dut_to_tg_if1_ip} | ${prefix_len}
229 | | Honeycomb sets interface IPv6 address | ${dut_node}
230 | | ... | ${dut_to_tg_if2} | ${dut_to_tg_if2_ip} | ${prefix_len}
231 | | Honeycomb adds interface IPv6 neighbor | ${dut_node} | ${dut_to_tg_if1}
232 | | ... | ${src_ip} | ${tg_to_dut_if1_mac}
233 | | Honeycomb adds interface IPv6 neighbor | ${dut_node} | ${dut_to_tg_if2}
234 | | ... | ${next_hop} | ${tg_to_dut_if2_mac}
235 | | Vpp all ra suppress link layer | ${nodes}
236
237 | Honeycomb routing test teardown
238 | | ...
239 | | [arguments] | ${node} | ${routing_table}
240 | | ...
241 | | Show Packet Trace on All DUTs | ${nodes}
242 | | Log routing configuration from VAT | ${node}
243 | | Honeycomb removes routing configuration | ${node} | ${routing_table}
244
245 | Setup vrf IDs
246 | | ...
247 | | [Arguments] | ${node} | ${interface} | ${vrf}
248 | | ...
249 | | Honeycomb sets interface VRF ID
250 | | ... | ${node} | ${interface} | ${vrf} | ipv4
251 | | Honeycomb sets interface VRF ID
252 | | ... | ${node} | ${interface} | ${vrf} | ipv6