Skip to content

Commit 95be986

Browse files
authored
chore: ignore log analyzer (#21305)
Signed-off-by: Austin Pham <[email protected]>
1 parent 3b2fa09 commit 95be986

File tree

1 file changed

+30
-1
lines changed

1 file changed

+30
-1
lines changed

tests/iface_namingmode/test_iface_namingmode.py

Lines changed: 30 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,31 @@
2222
QUEUE_COUNTERS_RE_FMT = r'{}\s+[U|M]C|ALL\d\s+\S+\s+\S+\s+\S+\s+\S+'
2323

2424

25+
@pytest.fixture
26+
def ignore_host_lane_count_loganalyzer(enum_rand_one_per_hwsku_frontend_hostname, loganalyzer):
27+
def wrapper(ignore_condition=False):
28+
"""
29+
Ignore expected failures logs during test execution.
30+
31+
LAG tests are triggering following syncd complaints but the don't cause
32+
harm to DUT.
33+
34+
Args:
35+
duthost: DUT fixture
36+
loganalyzer: Loganalyzer utility fixture
37+
"""
38+
if not ignore_condition:
39+
return
40+
# when loganalyzer is disabled, the object could be None
41+
if loganalyzer:
42+
ignoreRegex = [
43+
(".*ERR pmon#xcvrd.*: no suitable app for the port appl .* host_lane_count [0-9] host_speed.*"),
44+
]
45+
loganalyzer[enum_rand_one_per_hwsku_frontend_hostname].ignore_regex.extend(ignoreRegex)
46+
47+
yield wrapper
48+
49+
2550
@pytest.fixture(autouse=True)
2651
def ignore_expected_loganalyzer_exception(duthosts, enum_rand_one_per_hwsku_frontend_hostname, loganalyzer):
2752
if loganalyzer:
@@ -1169,7 +1194,8 @@ def _lldp_exists(expected=True):
11691194
"LLDP neighbor should exist for interface {}".format(test_intf))
11701195

11711196
def test_config_interface_speed(self, setup_config_mode, sample_intf,
1172-
duthosts, enum_rand_one_per_hwsku_frontend_hostname):
1197+
duthosts, enum_rand_one_per_hwsku_frontend_hostname,
1198+
ignore_host_lane_count_loganalyzer):
11731199
"""
11741200
Checks whether 'config interface speed <intf> <speed>' sets
11751201
speed of the test interface when its interface alias/name is
@@ -1190,6 +1216,9 @@ def test_config_interface_speed(self, setup_config_mode, sample_intf,
11901216
# Set speed to configure
11911217
configure_speed = supported_speeds[0] if supported_speeds else native_speed
11921218

1219+
ignore_host_lane_count_loganalyzer(ignore_condition=duthost.facts['hwsku'] in ["Arista-7060X6-64PE-P32O64",
1220+
"Arista-7060X6-64PE-P64"])
1221+
11931222
if not self.check_speed_change(duthost, asic_index, interface, configure_speed):
11941223
pytest.skip(
11951224
"Cisco-88-LC0-36FH-M-O36 and Cisco-88-LC0-36FH-O36 \

0 commit comments

Comments
 (0)