From d82fe7928ade3d246dfb51559f2e7bf0bd8a6fd2 Mon Sep 17 00:00:00 2001 From: Yuriy Zveryanskyy Date: Fri, 4 Dec 2015 11:14:27 +0200 Subject: [PATCH] Fix awake AMT unit test If test methods of awake AMT test case executed on the same process with short time between executions tests fails. This patch adds reset of AMT_AWAKE_CACHE to setUp() method. Closes-bug: #1522789 Change-Id: I91c2e60bd2a3a1f97de3a7256e78815ddbbf8087 --- ironic/tests/unit/drivers/modules/amt/test_common.py | 1 + 1 file changed, 1 insertion(+) diff --git a/ironic/tests/unit/drivers/modules/amt/test_common.py b/ironic/tests/unit/drivers/modules/amt/test_common.py index 60aa2ce92b..f83ce9c31a 100644 --- a/ironic/tests/unit/drivers/modules/amt/test_common.py +++ b/ironic/tests/unit/drivers/modules/amt/test_common.py @@ -179,6 +179,7 @@ class AMTCommonClientTestCase(base.TestCase): class AwakeAMTInterfaceTestCase(db_base.DbTestCase): def setUp(self): super(AwakeAMTInterfaceTestCase, self).setUp() + amt_common.AMT_AWAKE_CACHE = {} self.info = INFO_DICT self.node = obj_utils.create_test_node(self.context, driver='fake_amt',