@@ -280,9 +280,6 @@ def create_and_test_neighbor(self, confdb, appdb, asicdb, dvs, dvs_route):
280
280
self .add_neighbor (dvs , self .SERV1_IPV6 , "00:00:00:00:00:01" )
281
281
srv1_v6 = self .check_neigh_in_asic_db (asicdb , self .SERV1_IPV6 )
282
282
283
- self .add_neighbor (dvs , self .SERV1_SOC_IPV4 , "00:00:00:00:00:01" )
284
- srv1_soc_v4 = self .check_neigh_in_asic_db (asicdb , self .SERV1_SOC_IPV4 )
285
-
286
283
existing_keys = asicdb .get_keys (self .ASIC_NEIGH_TABLE )
287
284
288
285
self .add_neighbor (dvs , self .SERV2_IPV4 , "00:00:00:00:00:02" )
@@ -294,47 +291,47 @@ def create_and_test_neighbor(self, confdb, appdb, asicdb, dvs, dvs_route):
294
291
dvs_route .check_asicdb_route_entries (
295
292
[self .SERV2_IPV4 + self .IPV4_MASK , self .SERV2_IPV6 + self .IPV6_MASK ]
296
293
)
297
- self .check_tunnel_route_in_app_db (
298
- dvs ,
299
- [self .SERV2_IPV4 + self .IPV4_MASK , self .SERV2_IPV6 + self .IPV6_MASK ]
300
- )
301
294
302
295
# The first standby route also creates as tunnel Nexthop
303
- self .check_tnl_nexthop_in_asic_db (asicdb , 4 )
296
+ self .check_tnl_nexthop_in_asic_db (asicdb , 3 )
304
297
305
298
# Change state to Standby. This will delete Neigh and add Route
306
299
self .set_mux_state (appdb , "Ethernet0" , "standby" )
307
300
308
301
asicdb .wait_for_deleted_entry (self .ASIC_NEIGH_TABLE , srv1_v4 )
309
302
asicdb .wait_for_deleted_entry (self .ASIC_NEIGH_TABLE , srv1_v6 )
310
- asicdb .wait_for_deleted_entry (self .ASIC_NEIGH_TABLE , srv1_soc_v4 )
311
303
dvs_route .check_asicdb_route_entries (
312
- [self .SERV1_IPV4 + self .IPV4_MASK , self .SERV1_IPV6 + self .IPV6_MASK , self .SERV1_SOC_IPV4 + self .IPV4_MASK ]
313
- )
314
- self .check_tunnel_route_in_app_db (
315
- dvs ,
316
304
[self .SERV1_IPV4 + self .IPV4_MASK , self .SERV1_IPV6 + self .IPV6_MASK ]
317
305
)
318
- self .check_tunnel_route_in_app_db (
319
- dvs ,
320
- [self .SERV1_SOC_IPV4 + self .IPV4_MASK ],
321
- expected = False
322
- )
323
306
324
307
# Change state to Active. This will add Neigh and delete Route
325
308
self .set_mux_state (appdb , "Ethernet4" , "active" )
326
309
327
310
dvs_route .check_asicdb_deleted_route_entries (
328
- [self .SERV2_IPV4 + self .IPV4_MASK , self .SERV2_IPV6 + self .IPV6_MASK , self . SERV1_SOC_IPV4 + self . IPV4_MASK ]
311
+ [self .SERV2_IPV4 + self .IPV4_MASK , self .SERV2_IPV6 + self .IPV6_MASK ]
329
312
)
330
313
self .check_neigh_in_asic_db (asicdb , self .SERV2_IPV4 )
331
314
self .check_neigh_in_asic_db (asicdb , self .SERV2_IPV6 )
332
- self .check_neigh_in_asic_db (asicdb , self .SERV1_SOC_IPV4 )
333
- self .check_tunnel_route_in_app_db (
334
- dvs ,
335
- [self .SERV1_IPV4 + self .IPV4_MASK , self .SERV1_IPV6 + self .IPV6_MASK , self .SERV1_SOC_IPV4 + self .IPV4_MASK ],
336
- expected = False
315
+
316
+ def create_and_test_soc (self , appdb , asicdb , dvs , dvs_route ):
317
+
318
+ self .set_mux_state (appdb , "Ethernet0" , "active" )
319
+
320
+ self .add_fdb (dvs , "Ethernet0" , "00-00-00-00-00-01" )
321
+ self .add_neighbor (dvs , self .SERV1_SOC_IPV4 , "00:00:00:00:00:01" )
322
+
323
+ time .sleep (1 )
324
+
325
+ srv1_soc_v4 = self .check_neigh_in_asic_db (asicdb , self .SERV1_SOC_IPV4 )
326
+ self .check_tunnel_route_in_app_db (dvs , [self .SERV1_SOC_IPV4 + self .IPV4_MASK ], expected = False )
327
+
328
+ self .set_mux_state (appdb , "Ethernet0" , "standby" )
329
+
330
+ asicdb .wait_for_deleted_entry (self .ASIC_NEIGH_TABLE , srv1_soc_v4 )
331
+ dvs_route .check_asicdb_route_entries (
332
+ [self .SERV1_SOC_IPV4 + self .IPV4_MASK ]
337
333
)
334
+ self .check_tunnel_route_in_app_db (dvs , [self .SERV1_SOC_IPV4 + self .IPV4_MASK ], expected = False )
338
335
339
336
def create_and_test_fdb (self , appdb , asicdb , dvs , dvs_route ):
340
337
@@ -1136,6 +1133,11 @@ def test_neighbor_miss_no_peer(
1136
1133
for ip in test_ips :
1137
1134
self .check_neighbor_state (dvs , dvs_route , ip , expect_route = False )
1138
1135
1136
+ def test_soc_ip (self , dvs , dvs_route , setup_vlan , setup_mux_cable , testlog ):
1137
+ appdb = swsscommon .DBConnector (swsscommon .APPL_DB , dvs .redis_sock , 0 )
1138
+ asicdb = dvs .get_asic_db ()
1139
+
1140
+ self .create_and_test_soc (appdb , asicdb , dvs , dvs_route )
1139
1141
1140
1142
# Add Dummy always-pass test at end as workaroud
1141
1143
# for issue when Flaky fail on final test it invokes module tear-down before retrying
0 commit comments