Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cisco: Skip Watermark test for multi-DUT cases. #9810

Merged
merged 3 commits into from
Sep 22, 2023
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
16 changes: 16 additions & 0 deletions tests/qos/qos_sai_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -1944,3 +1944,19 @@ def select_port_ids_for_mellnaox_device(self, duthost, mgFacts, testPortIds):
max_port_num = len(port_list)
logger.info(f"Test ports ids is{test_port_ids}")
return test_port_ids

@pytest.fixture(scope="function", autouse=False)
def _skip_watermark_multi_DUT(
self,
get_src_dst_asic_and_duts,
dutQosConfig):
if not is_cisco_device(get_src_dst_asic_and_duts['src_dut']):
yield
return
if (get_src_dst_asic_and_duts['src_dut'] !=
get_src_dst_asic_and_duts['dst_dut']):
pytest.skip(
"All WM Tests are skipped for multiDUT for cisco platforms.")

yield
return
8 changes: 4 additions & 4 deletions tests/qos/test_qos_sai.py
Original file line number Diff line number Diff line change
Expand Up @@ -889,7 +889,7 @@ def testQosSaiHeadroomPoolWatermark(
@pytest.mark.parametrize("bufPool", ["wm_buf_pool_lossless", "wm_buf_pool_lossy"])
def testQosSaiBufferPoolWatermark(
self, request, get_src_dst_asic_and_duts, bufPool, ptfhost, dutTestParams, dutConfig, dutQosConfig,
ingressLosslessProfile, egressLossyProfile, resetWatermark,
ingressLosslessProfile, egressLossyProfile, resetWatermark, _skip_watermark_multi_DUT
):
"""
Test QoS SAI Queue buffer pool watermark for lossless/lossy traffic
Expand Down Expand Up @@ -1365,7 +1365,7 @@ def testQosSaiDwrr(
@pytest.mark.parametrize("pgProfile", ["wm_pg_shared_lossless", "wm_pg_shared_lossy"])
def testQosSaiPgSharedWatermark(
self, pgProfile, ptfhost, get_src_dst_asic_and_duts, dutTestParams, dutConfig, dutQosConfig,
resetWatermark
resetWatermark, _skip_watermark_multi_DUT
):
"""
Test QoS SAI PG shared watermark test for lossless/lossy traffic
Expand Down Expand Up @@ -1565,7 +1565,7 @@ def testQosSaiPGDrop(
@pytest.mark.parametrize("queueProfile", ["wm_q_shared_lossless", "wm_q_shared_lossy"])
def testQosSaiQSharedWatermark(
self, get_src_dst_asic_and_duts, queueProfile, ptfhost, dutTestParams, dutConfig, dutQosConfig,
resetWatermark
resetWatermark, _skip_watermark_multi_DUT
):
"""
Test QoS SAI Queue shared watermark test for lossless/lossy traffic
Expand Down Expand Up @@ -1819,7 +1819,7 @@ def testQosSaiDwrrWeightChange(
@pytest.mark.parametrize("queueProfile", ["wm_q_wm_all_ports"])
def testQosSaiQWatermarkAllPorts(
self, queueProfile, ptfhost, dutTestParams, dutConfig, dutQosConfig,
resetWatermark
resetWatermark, _skip_watermark_multi_DUT
):
"""
Test QoS SAI Queue watermark test for lossless/lossy traffic on all ports
Expand Down