diff options
author | Zuul <zuul@review.opendev.org> | 2023-02-20 15:27:21 +0000 |
---|---|---|
committer | Gerrit Code Review <review@openstack.org> | 2023-02-20 15:27:21 +0000 |
commit | 3707422bf70af2926744f669b6447da8f2ec2d67 (patch) | |
tree | fa52f2d756ab72eb2a8f7fc1fa75b914949ca5a5 /ironic/tests/unit/drivers/modules | |
parent | c130d063b69901193df5c0f023250ce2f4d822a6 (diff) | |
parent | c9c9b3100d3bd8983ca53a75c4a4e5f9c7f122b9 (diff) | |
download | ironic-3707422bf70af2926744f669b6447da8f2ec2d67.tar.gz |
Merge "Fixes console port conflict occurs in certain path"
Diffstat (limited to 'ironic/tests/unit/drivers/modules')
-rw-r--r-- | ironic/tests/unit/drivers/modules/test_ipmitool.py | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/ironic/tests/unit/drivers/modules/test_ipmitool.py b/ironic/tests/unit/drivers/modules/test_ipmitool.py index b982e0cb2..016b9d6ed 100644 --- a/ironic/tests/unit/drivers/modules/test_ipmitool.py +++ b/ironic/tests/unit/drivers/modules/test_ipmitool.py @@ -3255,6 +3255,11 @@ class IPMIToolShellinaboxTestCase(db_base.DbTestCase): mock_start.return_value = None mock_info.return_value = {'port': None} mock_alloc.return_value = 1234 + # Ensure allocated port is not re-used + dii = self.node.driver_internal_info + dii['allocated_ipmi_terminal_port'] = 4321 + self.node.driver_internal_info = dii + self.node.save() with task_manager.acquire(self.context, self.node.uuid) as task: @@ -3468,6 +3473,11 @@ class IPMIToolSocatDriverTestCase(IPMIToolShellinaboxTestCase): mock_start.return_value = None mock_info.return_value = {'port': None} mock_alloc.return_value = 1234 + # Ensure allocated port is not re-used + dii = self.node.driver_internal_info + dii['allocated_ipmi_terminal_port'] = 4321 + self.node.driver_internal_info = dii + self.node.save() with task_manager.acquire(self.context, self.node.uuid) as task: |