diff options
author | Michael Johnson <johnsomor@gmail.com> | 2023-02-16 00:39:03 +0000 |
---|---|---|
committer | Michael Johnson <johnsomor@gmail.com> | 2023-02-16 00:41:55 +0000 |
commit | 8e2286c9b2d9afb5c1750f2ccf7ec27e8a03e9cf (patch) | |
tree | 221655aa180f98a47be96f152c7bd791e0843f02 | |
parent | 85480f94dc6c346399791ae83f380ff5c9eb0add (diff) | |
download | heat-8e2286c9b2d9afb5c1750f2ccf7ec27e8a03e9cf.tar.gz |
Fix unit tests for python-barbicanclient 5.5.0
Version 5.5.0 of python-barbicanclient adds microversion support,
which causes it to call keystoneauth1.discover.get_version_data
to get the microversion information from the server. Adding
additional mock.patch for keystoneauth1.discover fixes the
breaking unit tests.
This is a gate fix for the python-barbicanclient upper-constraints bump[1].
[1] https://review.opendev.org/c/openstack/requirements/+/873906
Co-Authored-By: Grzegorz Grasza <xek@redhat.com>
Change-Id: Ic1c26d255ff0690e327b3cb6c622d3617e02df5f
-rw-r--r-- | heat/tests/clients/test_barbican_client.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/heat/tests/clients/test_barbican_client.py b/heat/tests/clients/test_barbican_client.py index 6159ab70e..4f07dc681 100644 --- a/heat/tests/clients/test_barbican_client.py +++ b/heat/tests/clients/test_barbican_client.py @@ -32,6 +32,8 @@ class BarbicanClientPluginTest(common.HeatTestCase): self.barbican_plugin = c.client_plugin('barbican') self.barbican_plugin.client = lambda: self.barbican_client + @mock.patch('keystoneauth1.discover.get_version_data', + mock.MagicMock(return_value=[{'status': "STABLE"}])) def test_create(self): context = utils.dummy_context() plugin = context.clients.client_plugin('barbican') |