Skip to content

Commit

Permalink
Skip non applicable assertions for Innovium asic: expected_wm <= hdrm…
Browse files Browse the repository at this point in the history
…_pool_wm (#6357)

Skip non applicable assertions for Innovium asic: expected_wm <= hdrm_pool_wm

What is the motivation for this PR?
Update testQosSaiHeadroomPoolWatermark for Innovium platform

How did you do it?
Skip non applicable assertions for Innovium asic

How did you verify/test it?
Run testQosSaiHeadroomPoolWatermark on local setup and testcase passes
  • Loading branch information
maulik-marvell authored Nov 6, 2022
1 parent 8580f64 commit f7319d4
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions tests/saitests/py3/sai_qos_tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -1927,7 +1927,8 @@ def runTest(self):

print("pkts sent: %d, lower bound: %d, actual headroom pool watermark: %d, upper_bound: %d" % (
wm_pkt_num, expected_wm, hdrm_pool_wm, upper_bound_wm), file=sys.stderr)
assert(expected_wm <= hdrm_pool_wm)
if 'innovium' not in self.asic_type:
assert(expected_wm <= hdrm_pool_wm)
assert(hdrm_pool_wm <= upper_bound_wm)

print("all but the last pg hdrms filled", file=sys.stderr)
Expand Down Expand Up @@ -1958,7 +1959,8 @@ def runTest(self):
# assert hdrm pool wm still remains the same
hdrm_pool_wm = sai_thrift_read_headroom_pool_watermark(
self.client, self.buf_pool_roid)
assert(expected_wm <= hdrm_pool_wm)
if 'innovium' not in self.asic_type:
assert(expected_wm <= hdrm_pool_wm)
assert(hdrm_pool_wm <= upper_bound_wm)
# at this point headroom pool should be full. send few more packets to continue causing drops
print("overflow headroom pool", file=sys.stderr)
Expand Down

0 comments on commit f7319d4

Please sign in to comment.