Skip to content

Commit c032bdf

Browse files
committed
[MASIC] disable thermalctld when running test_fan_drawer_fans.py (#5529)
* Update test_po_cleanup.py Update same changes in master branch from PR: (#5453) * Update test_fan_drawer_fans.py * Update test_fan_drawer_fans.py * Update test_fan_drawer_fans.py Disable thermalctld when running test_fan_drawer_fans.py (cherry picked from commit 35f25e1)
1 parent b75ed09 commit c032bdf

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

tests/platform_tests/api/test_fan_drawer_fans.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
from tests.common.helpers.assertions import pytest_assert
1010
from tests.common.helpers.platform_api import chassis, fan_drawer, fan_drawer_fan
11-
11+
from tests.platform_tests.thermal_control_test_helper import start_thermal_control_daemon, stop_thermal_control_daemon
1212
from platform_api_test_base import PlatformApiTestBase
1313

1414
###################################################
@@ -48,7 +48,7 @@ class TestFanDrawerFans(PlatformApiTestBase):
4848
# level, so we must do the same here to prevent a scope mismatch.
4949

5050
@pytest.fixture(scope="function", autouse=True)
51-
def setup(self, platform_api_conn):
51+
def setup(self, platform_api_conn, duthost):
5252
if self.num_fan_drawers is None:
5353
try:
5454
self.num_fan_drawers = chassis.get_num_fan_drawers(platform_api_conn)
@@ -57,7 +57,9 @@ def setup(self, platform_api_conn):
5757
else:
5858
if self.num_fan_drawers == 0:
5959
pytest.skip("No fan drawers found on device")
60-
60+
stop_thermal_control_daemon(duthost)
61+
yield
62+
start_thermal_control_daemon(duthost)
6163
#
6264
# Helper functions
6365
#

0 commit comments

Comments
 (0)