From 18c36c46aacc1e01e31d62367977f7b392b266dc Mon Sep 17 00:00:00 2001 From: selldinesh Date: Tue, 3 Oct 2023 18:40:46 +0000 Subject: [PATCH] reverting sai and l2 basic --- common/sai.py | 6 ++++-- tests/api/test_isolation_group_member.py | 13 +++++++++++++ tests/test_l2_basic.py | 2 +- 3 files changed, 18 insertions(+), 3 deletions(-) diff --git a/common/sai.py b/common/sai.py index 3b7fd28b..623dbcc7 100644 --- a/common/sai.py +++ b/common/sai.py @@ -338,7 +338,9 @@ def get_by_type(self, obj, attr, attr_type, do_assert=False): unsupported_types = [ "sai_port_eye_values_list_t", "sai_prbs_rx_state_t", "sai_port_err_status_list_t", "sai_fabric_port_reachability_t", - "sai_port_lane_latch_status_list_t", "sai_latch_status_t" + "sai_port_lane_latch_status_list_t", "sai_latch_status_t", + "sai_port_frequency_offset_ppm_list_t", "sai_port_snr_list_t", + "sai_acl_chain_list_t" ] if attr_type == "sai_object_list_t": status, data = self.get(obj, [attr, "1:oid:0x0"], do_assert) @@ -710,4 +712,4 @@ def __parse_rec(self, fname): tokens = tokens[1:] data.append(tokens) rec[cnt] = data #if len(data) > 1 else data[0] - return rec + return rec \ No newline at end of file diff --git a/tests/api/test_isolation_group_member.py b/tests/api/test_isolation_group_member.py index 7fa6b50d..9ad26a24 100644 --- a/tests/api/test_isolation_group_member.py +++ b/tests/api/test_isolation_group_member.py @@ -1,6 +1,19 @@ from pprint import pprint +import pytest +@pytest.fixture(scope="module", autouse=True) +def discovery(npu): + npu.objects_discovery() + +@pytest.fixture(scope='module', autouse=True) +def skip_all(testbed_instance): + testbed = testbed_instance + if testbed is not None and len(testbed.npu) != 1: + pytest.skip('invalid for {} testbed'.format(testbed.name)) + + +@pytest.mark.npu class TestSaiIsolationGroupMember: # object with parent SAI_OBJECT_TYPE_ISOLATION_GROUP SAI_OBJECT_TYPE_PORT SAI_OBJECT_TYPE_BRIDGE_PORT diff --git a/tests/test_l2_basic.py b/tests/test_l2_basic.py index 33e6f82e..ce3e6d20 100644 --- a/tests/test_l2_basic.py +++ b/tests/test_l2_basic.py @@ -909,4 +909,4 @@ def test_l2_mac_move_1(npu, dataplane): npu.create_vlan_member(npu.default_vlan_oid, npu.dot1q_bp_oids[idx], "SAI_VLAN_TAGGING_MODE_UNTAGGED") npu.set(npu.port_oids[idx], ["SAI_PORT_ATTR_PORT_VLAN_ID", npu.default_vlan_id]) - npu.remove(vlan_oid) + npu.remove(vlan_oid) \ No newline at end of file