Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion tests/common/dualtor/dual_tor_mock.py
Original file line number Diff line number Diff line change
Expand Up @@ -343,7 +343,7 @@ def apply_peer_switch_table_to_dut(cleanup_mocked_configs, rand_selected_dut, mo
restart_swss = True
cmd = 'redis-cli -n 4 HSET "{}" "{}" "{}"'.format(device_meta_key, 'subtype', 'DualToR')
dut.shell(cmd=cmd)
if restart_swss:
if ((restart_swss) and (dut.get_asic_name() != 'gb')):
# Restart swss on TH2 or TD3 platform to trigger syncd restart to regenerate config.bcm
# We actually need to restart syncd only, but restarting syncd will also trigger swss
# being restarted, and it costs more time than restarting swss
Expand Down
2 changes: 1 addition & 1 deletion tests/dualtor/test_ipinip.py
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,7 @@ def stop_garp(ptfhost):

if is_t0_mocked_dualtor(tbinfo): # noqa F405
request.getfixturevalue('apply_active_state_to_orchagent')
time.sleep(30)
else:
request.getfixturevalue('toggle_all_simulator_ports_to_rand_selected_tor')

Expand All @@ -127,7 +128,6 @@ def stop_garp(ptfhost):

ptf_t1_intf = random.choice(get_t1_ptf_ports(tor, tbinfo))
logging.info("send encapsulated packet from ptf t1 interface %s", ptf_t1_intf)
time.sleep(10)
with stop_garp(ptfhost):
ptfadapter.dataplane.flush()
testutils.send(ptfadapter, int(ptf_t1_intf.strip("eth")), encapsulated_packet)
Expand Down
3 changes: 3 additions & 0 deletions tests/dualtor/test_orchagent_standby_tor_downstream.py
Original file line number Diff line number Diff line change
Expand Up @@ -360,19 +360,22 @@ def monitor_tunnel_and_server_traffic(torhost, expect_tunnel_traffic=True, expec
logger.info("Step 1.1: Add route to a nexthop which is a standby Neighbor")
set_mux_state(rand_selected_dut, tbinfo, 'standby', tor_mux_intfs, toggle_all_simulator_ports)
add_nexthop_routes(rand_selected_dut, random_dst_ip, nexthops=[target_server])
time.sleep(30)
logger.info("Step 1.2: Verify traffic to this route dst is forwarded to Active ToR and equally distributed")
check_tunnel_balance(**test_params)
monitor_tunnel_and_server_traffic(rand_selected_dut, expect_server_traffic=False, expect_tunnel_traffic=True)

logger.info("Stage 2: Verify Active Forwarding")
logger.info("Step 2.1: Simulate Mux state change to active")
set_mux_state(rand_selected_dut, tbinfo, 'active', tor_mux_intfs, toggle_all_simulator_ports)
time.sleep(30)
logger.info("Step 2.2: Verify traffic to this route dst is forwarded directly to server")
monitor_tunnel_and_server_traffic(rand_selected_dut, expect_server_traffic=True, expect_tunnel_traffic=False)

logger.info("Stage 3: Verify Standby Forwarding Again")
logger.info("Step 3.1: Simulate Mux state change to standby")
set_mux_state(rand_selected_dut, tbinfo, 'standby', tor_mux_intfs, toggle_all_simulator_ports)
time.sleep(30)
logger.info("Step 3.2: Verify traffic to this route dst \
is now redirected back to Active ToR and equally distributed")
monitor_tunnel_and_server_traffic(rand_selected_dut, expect_server_traffic=False, expect_tunnel_traffic=True)
Expand Down