summaryrefslogtreecommitdiff
path: root/ironic/tests/unit
diff options
context:
space:
mode:
authorZuul <zuul@review.opendev.org>2023-02-01 23:07:47 +0000
committerGerrit Code Review <review@openstack.org>2023-02-01 23:07:47 +0000
commit4704c74b4d028fa73bb465d43f7147702519dc2b (patch)
tree2dd9c22cd5593cfff8a270381cf2e66133bb994d /ironic/tests/unit
parentc9c595f235cec04e1fa67f52680f6f698229ddef (diff)
parent35349246acb384e1080558c7f3fb04314e81f709 (diff)
downloadironic-4704c74b4d028fa73bb465d43f7147702519dc2b.tar.gz
Merge "Fix snmp driver sleep call count"
Diffstat (limited to 'ironic/tests/unit')
-rw-r--r--ironic/tests/unit/drivers/modules/test_snmp.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/ironic/tests/unit/drivers/modules/test_snmp.py b/ironic/tests/unit/drivers/modules/test_snmp.py
index 00799dc4d..5391d7ac5 100644
--- a/ironic/tests/unit/drivers/modules/test_snmp.py
+++ b/ironic/tests/unit/drivers/modules/test_snmp.py
@@ -761,7 +761,7 @@ class SNMPDeviceDriverTestCase(db_base.DbTestCase):
driver = snmp._get_driver(self.node)
mock_client.get.return_value = driver.value_power_on
pstate = driver.power_on()
- mock_sleep.assert_called_once_with(1)
+ self.assertTrue(mock_sleep.called)
mock_client.set.assert_called_once_with(driver._snmp_oid(),
driver.value_power_on)
mock_client.get.assert_called_once_with(driver._snmp_oid())
@@ -775,7 +775,7 @@ class SNMPDeviceDriverTestCase(db_base.DbTestCase):
driver = snmp._get_driver(self.node)
mock_client.get.return_value = driver.value_power_off
pstate = driver.power_off()
- mock_sleep.assert_called_once_with(1)
+ self.assertTrue(mock_sleep.called)
mock_client.set.assert_called_once_with(driver._snmp_oid(),
driver.value_power_off)
mock_client.get.assert_called_once_with(driver._snmp_oid())