From b0a02a7ed85bd5a6f45af7ae490e0630d3ac3f9c Mon Sep 17 00:00:00 2001 From: Anant Kishor Sharma Date: Fri, 10 Mar 2023 00:58:43 -0800 Subject: [PATCH 1/7] skipping unknown mac test for cisco 8k --- tests/arp/test_unknown_mac.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/arp/test_unknown_mac.py b/tests/arp/test_unknown_mac.py index 0ee74f480b9..177f8242dc9 100644 --- a/tests/arp/test_unknown_mac.py +++ b/tests/arp/test_unknown_mac.py @@ -56,10 +56,10 @@ def unknownMacSetup(duthosts, rand_one_dut_hostname, tbinfo): """ duthost = duthosts[rand_one_dut_hostname] - # The behavior on Mellanox for unknown MAC is flooding rather than DROP, + # The behavior on Mellanox and cisco-8000 for unknown MAC is flooding rather than DROP, # so we need to skip this test on Mellanox platform asic_type = duthost.facts["asic_type"] - pytest_require(asic_type not in ["mellanox", "barefoot"], "Test is not supported for platform {}".format(asic_type)) + pytest_require(asic_type not in ["mellanox", "barefoot", "cisco-8000"], "Test is not supported for platform {}".format(asic_type)) mg_facts = duthost.get_extended_minigraph_facts(tbinfo) is_backend_topology = mg_facts.get(constants.IS_BACKEND_TOPOLOGY_KEY, False) From 44a4b010a9f8044c42aadf4061fc34cac2d364af Mon Sep 17 00:00:00 2001 From: Anant Kishor Sharma Date: Fri, 10 Mar 2023 01:31:13 -0800 Subject: [PATCH 2/7] fixing pre-commit error - tests/arp/test_unknown_mac.py:62:121: E501 line too long (134 > 120 characters) --- tests/arp/test_unknown_mac.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/arp/test_unknown_mac.py b/tests/arp/test_unknown_mac.py index 177f8242dc9..790b8feb431 100644 --- a/tests/arp/test_unknown_mac.py +++ b/tests/arp/test_unknown_mac.py @@ -59,7 +59,8 @@ def unknownMacSetup(duthosts, rand_one_dut_hostname, tbinfo): # The behavior on Mellanox and cisco-8000 for unknown MAC is flooding rather than DROP, # so we need to skip this test on Mellanox platform asic_type = duthost.facts["asic_type"] - pytest_require(asic_type not in ["mellanox", "barefoot", "cisco-8000"], "Test is not supported for platform {}".format(asic_type)) + pytest_require(asic_type not in ["mellanox", "barefoot", "cisco-8000"], + "Test is not supported for platform {}".format(asic_type)) mg_facts = duthost.get_extended_minigraph_facts(tbinfo) is_backend_topology = mg_facts.get(constants.IS_BACKEND_TOPOLOGY_KEY, False) From 7083bef7616e80a6a689611284dda2979df2f407 Mon Sep 17 00:00:00 2001 From: Anant Kishor Sharma Date: Fri, 10 Mar 2023 01:37:09 -0800 Subject: [PATCH 3/7] fixing pre-commit error - tests/arp/test_unknown_mac.py:63:38: E127 continuation line over-indented for visual indent --- tests/arp/test_unknown_mac.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/arp/test_unknown_mac.py b/tests/arp/test_unknown_mac.py index 790b8feb431..51513220458 100644 --- a/tests/arp/test_unknown_mac.py +++ b/tests/arp/test_unknown_mac.py @@ -60,7 +60,7 @@ def unknownMacSetup(duthosts, rand_one_dut_hostname, tbinfo): # so we need to skip this test on Mellanox platform asic_type = duthost.facts["asic_type"] pytest_require(asic_type not in ["mellanox", "barefoot", "cisco-8000"], - "Test is not supported for platform {}".format(asic_type)) + "Test is not supported for platform {}".format(asic_type)) mg_facts = duthost.get_extended_minigraph_facts(tbinfo) is_backend_topology = mg_facts.get(constants.IS_BACKEND_TOPOLOGY_KEY, False) From cd291c2e6d994c135906f620a6e27ff032323ae5 Mon Sep 17 00:00:00 2001 From: Anant Kishor Sharma Date: Tue, 21 Mar 2023 01:26:53 -0700 Subject: [PATCH 4/7] moving test case skip to condition yaml --- .../plugins/conditional_mark/tests_mark_conditions.yaml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/tests/common/plugins/conditional_mark/tests_mark_conditions.yaml b/tests/common/plugins/conditional_mark/tests_mark_conditions.yaml index 45121093b66..f65ab22be94 100644 --- a/tests/common/plugins/conditional_mark/tests_mark_conditions.yaml +++ b/tests/common/plugins/conditional_mark/tests_mark_conditions.yaml @@ -33,6 +33,12 @@ arp/test_arp_dualtor.py::test_proxy_arp_for_standby_neighbor: conditions: - "release not in ['202012']" +arp/test_unknown_mac.py: + skip: + reason: "Not supported on cisco-8000 all releases asics" + conditions: + - "asic_type in ['cisco-8000']" + ####################################### ##### bfd ##### ####################################### From 43b2c3fa07c4ac575a5b2e8b337a2424758fdffc Mon Sep 17 00:00:00 2001 From: Anant Kishor Sharma Date: Tue, 21 Mar 2023 01:33:08 -0700 Subject: [PATCH 5/7] removing test case skip from script --- tests/arp/test_unknown_mac.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/tests/arp/test_unknown_mac.py b/tests/arp/test_unknown_mac.py index 51513220458..0ee74f480b9 100644 --- a/tests/arp/test_unknown_mac.py +++ b/tests/arp/test_unknown_mac.py @@ -56,11 +56,10 @@ def unknownMacSetup(duthosts, rand_one_dut_hostname, tbinfo): """ duthost = duthosts[rand_one_dut_hostname] - # The behavior on Mellanox and cisco-8000 for unknown MAC is flooding rather than DROP, + # The behavior on Mellanox for unknown MAC is flooding rather than DROP, # so we need to skip this test on Mellanox platform asic_type = duthost.facts["asic_type"] - pytest_require(asic_type not in ["mellanox", "barefoot", "cisco-8000"], - "Test is not supported for platform {}".format(asic_type)) + pytest_require(asic_type not in ["mellanox", "barefoot"], "Test is not supported for platform {}".format(asic_type)) mg_facts = duthost.get_extended_minigraph_facts(tbinfo) is_backend_topology = mg_facts.get(constants.IS_BACKEND_TOPOLOGY_KEY, False) From 0a8455fed1e7981ee79306181620ec68d5f73d67 Mon Sep 17 00:00:00 2001 From: Anant <127479400+AnantKishorSharma@users.noreply.github.com> Date: Tue, 28 Mar 2023 09:19:11 +0530 Subject: [PATCH 6/7] Update tests_mark_conditions.yaml --- .../common/plugins/conditional_mark/tests_mark_conditions.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/common/plugins/conditional_mark/tests_mark_conditions.yaml b/tests/common/plugins/conditional_mark/tests_mark_conditions.yaml index f65ab22be94..1a6e74885f2 100644 --- a/tests/common/plugins/conditional_mark/tests_mark_conditions.yaml +++ b/tests/common/plugins/conditional_mark/tests_mark_conditions.yaml @@ -35,7 +35,7 @@ arp/test_arp_dualtor.py::test_proxy_arp_for_standby_neighbor: arp/test_unknown_mac.py: skip: - reason: "Not supported on cisco-8000 all releases asics" + reason: "Not supported on cisco-8000 platform" conditions: - "asic_type in ['cisco-8000']" From 770a2fedb8d37603747bd9243704154d1d910348 Mon Sep 17 00:00:00 2001 From: Anant <127479400+AnantKishorSharma@users.noreply.github.com> Date: Thu, 30 Mar 2023 11:25:00 +0530 Subject: [PATCH 7/7] Update tests_mark_conditions.yaml --- .../common/plugins/conditional_mark/tests_mark_conditions.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/common/plugins/conditional_mark/tests_mark_conditions.yaml b/tests/common/plugins/conditional_mark/tests_mark_conditions.yaml index ab7dd42e3df..038a8a689e4 100644 --- a/tests/common/plugins/conditional_mark/tests_mark_conditions.yaml +++ b/tests/common/plugins/conditional_mark/tests_mark_conditions.yaml @@ -41,7 +41,7 @@ arp/test_stress_arp.py: arp/test_unknown_mac.py: skip: - reason: "Not supported on cisco-8000 platform" + reason: "Behavior on cisco-8000 platform for unknown MAC is flooding rather than DROP, hence skipping." conditions: - "asic_type in ['cisco-8000']"