Skip to content

Commit 931e636

Browse files
alawingmssonicbld
authored andcommitted
Added sonic-clears on beginning of stup_neighbors (#14251)
1 parent 64ba148 commit 931e636

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

tests/ecmp/test_fgnhg.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,8 +66,8 @@ def configure_interfaces(cfg_facts, duthost, ptfhost, vlan_ip):
6666
ptf_to_dut_port_map[ptf_port_id] = port
6767

6868
port_list.sort()
69-
bank_0_port = port_list[:len(port_list)/2]
70-
bank_1_port = port_list[len(port_list)/2:]
69+
bank_0_port = port_list[:len(port_list)//2]
70+
bank_1_port = port_list[len(port_list)//2:]
7171

7272
# Create vlan if
7373
duthost.command('config interface ip add Vlan' + str(DEFAULT_VLAN_ID) + ' ' + str(vlan_ip))
@@ -111,6 +111,9 @@ def generate_fgnhg_config(duthost, ip_to_port, bank_0_port, bank_1_port):
111111

112112

113113
def setup_neighbors(duthost, ptfhost, ip_to_port):
114+
duthost.shell("sonic-clear fdb all")
115+
duthost.shell("sonic-clear arp")
116+
duthost.shell("sonic-clear ndp")
114117
vlan_name = "Vlan" + str(DEFAULT_VLAN_ID)
115118
neigh_entries = {}
116119
neigh_entries['NEIGH'] = {}

0 commit comments

Comments
 (0)