Skip to content

Commit

Permalink
gbp: More reliable unit-tests
Browse files Browse the repository at this point in the history
Type: fix

the GBP unit tests would peridocially fail. The reason being that there
is dynamic state whose presence nneds to be created, tested and then
timeed out. The failures occurded when the timeout occured before the
state could be tested. the previous timeout was 2 seconds, this has been
doubled, as a result i saw no faliures running continuously for ~16
hours.
bumping the timer increasing the test run time from ~40 to ~53 seconds,
a small price to pay.

in test cases where the state is not timed out i bumped the timer to 60
seconds.

Signed-off-by: Neale Ranns <nranns@cisco.com>
Change-Id: I11b0970570caa8eebf486fe8cd8e44a4b2b1fc36
  • Loading branch information
Neale Ranns authored and ayourtch committed Apr 8, 2020
1 parent 61717cc commit 8d0d8d2
Showing 1 changed file with 16 additions and 16 deletions.
32 changes: 16 additions & 16 deletions src/plugins/gbp/test/test_gbp.py
Original file line number Diff line number Diff line change
Expand Up @@ -1578,13 +1578,13 @@ def test_gbp_learn_l2(self):
None, self.loop0,
"10.0.0.128",
"2001:10::128",
VppGbpEndpointRetention(2))
VppGbpEndpointRetention(4))
epg_220.add_vpp_config()
epg_330 = VppGbpEndpointGroup(self, 330, 113, rd1, gbd1,
None, self.loop1,
"10.0.1.128",
"2001:11::128",
VppGbpEndpointRetention(2))
VppGbpEndpointRetention(4))
epg_330.add_vpp_config()

#
Expand Down Expand Up @@ -2457,7 +2457,7 @@ def test_gbp_bd_drop_flags(self):
None, self.loop0,
"10.0.0.128",
"2001:10::128",
VppGbpEndpointRetention(2))
VppGbpEndpointRetention(3))
epg_220.add_vpp_config()

ep = VppGbpEndpoint(self, self.pg0,
Expand Down Expand Up @@ -2631,7 +2631,7 @@ def test_gbp_learn_vlan_l2(self):
None, self.loop0,
"10.0.0.128",
"2001:10::128",
VppGbpEndpointRetention(2))
VppGbpEndpointRetention(4))
epg_220.add_vpp_config()

#
Expand Down Expand Up @@ -2807,7 +2807,7 @@ def test_gbp_learn_l3(self):
None, self.loop0,
"10.0.0.128",
"2001:10::128",
VppGbpEndpointRetention(2))
VppGbpEndpointRetention(4))
epg_220.add_vpp_config()

#
Expand Down Expand Up @@ -3309,19 +3309,19 @@ def test_gbp_redirect(self):
None, gbd1.bvi,
"10.0.0.128",
"2001:10::128",
VppGbpEndpointRetention(2))
VppGbpEndpointRetention(60))
epg_220.add_vpp_config()
epg_221 = VppGbpEndpointGroup(self, 221, 441, rd1, gbd2,
None, gbd2.bvi,
"10.0.1.128",
"2001:11::128",
VppGbpEndpointRetention(2))
VppGbpEndpointRetention(60))
epg_221.add_vpp_config()
epg_222 = VppGbpEndpointGroup(self, 222, 442, rd1, gbd1,
None, gbd1.bvi,
"10.0.2.128",
"2001:12::128",
VppGbpEndpointRetention(2))
VppGbpEndpointRetention(60))
epg_222.add_vpp_config()

#
Expand Down Expand Up @@ -3352,13 +3352,13 @@ def test_gbp_redirect(self):
None, gbd1.bvi,
"12.0.0.128",
"4001:10::128",
VppGbpEndpointRetention(2))
VppGbpEndpointRetention(60))
epg_320.add_vpp_config()
epg_321 = VppGbpEndpointGroup(self, 321, 551, rd1, gbd4,
None, gbd2.bvi,
"12.0.1.128",
"4001:11::128",
VppGbpEndpointRetention(2))
VppGbpEndpointRetention(60))
epg_321.add_vpp_config()

#
Expand Down Expand Up @@ -3870,7 +3870,7 @@ def test_gbp_redirect(self):
None, gebd.bvi,
"10.1.0.128",
"2001:10:1::128",
VppGbpEndpointRetention(2))
VppGbpEndpointRetention(60))
eepg.add_vpp_config()
# add subnets to BVI
VppIpInterfaceAddress(
Expand Down Expand Up @@ -4232,13 +4232,13 @@ def test_gbp_redirect_extended(self):
None, gbd1.bvi,
"10.0.0.128",
"2001:10::128",
VppGbpEndpointRetention(2))
VppGbpEndpointRetention(60))
epg_220.add_vpp_config()
epg_221 = VppGbpEndpointGroup(self, 221, 441, rd1, gbd2,
None, gbd2.bvi,
"10.0.1.128",
"2001:11::128",
VppGbpEndpointRetention(2))
VppGbpEndpointRetention(60))
epg_221.add_vpp_config()

#
Expand Down Expand Up @@ -4273,7 +4273,7 @@ def test_gbp_redirect_extended(self):
None, gbd3.bvi,
"12.0.0.128",
"4001:10::128",
VppGbpEndpointRetention(2))
VppGbpEndpointRetention(60))
epg_320.add_vpp_config()

#
Expand Down Expand Up @@ -4649,7 +4649,7 @@ def test_gbp_l3_out(self):
None, gbd1.bvi,
"10.0.0.128",
"2001:10::128",
VppGbpEndpointRetention(2))
VppGbpEndpointRetention(4))
epg_220.add_vpp_config()

# the BVIs have the subnets applied ...
Expand Down Expand Up @@ -5427,7 +5427,7 @@ def test_gbp_anon_l3_out(self):
None, gbd1.bvi,
"10.0.0.128",
"2001:10::128",
VppGbpEndpointRetention(2))
VppGbpEndpointRetention(4))
epg_220.add_vpp_config()

# the BVIs have the subnet applied ...
Expand Down

0 comments on commit 8d0d8d2

Please sign in to comment.