diff --git a/tests/qos/qos_sai_base.py b/tests/qos/qos_sai_base.py index 6e64f21e80..05ed5531b5 100644 --- a/tests/qos/qos_sai_base.py +++ b/tests/qos/qos_sai_base.py @@ -2035,6 +2035,22 @@ def skip_check_for_hbm_either_asic(self, get_src_dst_asic_and_duts): yield return + @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 + def select_port_ids_for_mellnaox_device(self, duthost, mgFacts, testPortIds): """ For Nvidia devices, the tested ports must have the same cable length and speed. diff --git a/tests/qos/test_qos_sai.py b/tests/qos/test_qos_sai.py index 9a84548e4b..bdfc1bb332 100755 --- a/tests/qos/test_qos_sai.py +++ b/tests/qos/test_qos_sai.py @@ -911,7 +911,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 @@ -1384,7 +1384,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 @@ -1581,7 +1581,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 @@ -1838,7 +1838,8 @@ def testQosSaiDwrrWeightChange( @pytest.mark.parametrize("queueProfile", ["wm_q_wm_all_ports"]) def testQosSaiQWatermarkAllPorts( self, queueProfile, ptfhost, dutTestParams, dutConfig, dutQosConfig, - resetWatermark, get_src_dst_asic_and_duts, dut_qos_maps + resetWatermark, get_src_dst_asic_and_duts, dut_qos_maps, + _skip_watermark_multi_DUT ): """ Test QoS SAI Queue watermark test for lossless/lossy traffic on all ports