Description of problem: Running any barbican tempest tests fail. Version-Release number of selected component (if applicable): python2-barbican-tests-tempest.noarch 0.0.1-0.20180328044348.5ddcc7e.el7ost python2-tempest.noarch 1:18.0.0-8.el7ost python2-tempestconf.noarch 2.2.0-1.el7ost How reproducible: Everytime Steps to Reproduce: 1. ostestr --regex barbican 2. 3. Actual results: {3} setUpClass (barbican_tempest_plugin.tests.scenario.test_image_signing.ImageSigningSnapshotTest) [0.000000s] ... FAILED Captured traceback: ~~~~~~~~~~~~~~~~~~~ Traceback (most recent call last): File "/usr/lib/python2.7/site-packages/tempest/test.py", line 172, in setUpClass six.reraise(etype, value, trace) File "/usr/lib/python2.7/site-packages/tempest/test.py", line 162, in setUpClass cls.setup_clients() File "/usr/lib/python2.7/site-packages/barbican_tempest_plugin/tests/scenario/test_image_signing.py", line 92, in setup_clients super(ImageSigningSnapshotTest, cls).setup_clients() File "/usr/lib/python2.7/site-packages/barbican_tempest_plugin/tests/scenario/barbican_manager.py", line 67, in setup_clients super(BarbicanScenarioTest, cls).setup_clients() File "/usr/lib/python2.7/site-packages/barbican_tempest_plugin/tests/scenario/manager.py", line 82, in setup_clients cls.volumes_client = cls.os_primary.volumes_client AttributeError: 'Manager' object has no attribute 'volumes_client' Expected results: Test should pass Additional info: You will reach this condition if tempest.conf is as follows: [volume-feature-enabled] # Setting v2 to false is what breaks it. api_v2 = False api_v3 = True I was able to hack manager.py and barbican_manager.py to work correctly with the installed version of tempest. # Logic is wrong in # /usr/lib/python2.7/site-packages/barbican_tempest_plugin/tests/scenario/manager.py#79 if CONF.volume_feature_enabled.api_v2: cls.volumes_client = cls.os_primary.volumes_v2_client cls.snapshots_client = cls.os_primary.snapshots_v2_client else: cls.volumes_client = cls.os_primary.volumes_client cls.snapshots_client = cls.os_primary.snapshots_client # we only need to check for api_v1 and if it is enabled we use volumes_client, # otherwise for api v2 and v3 we just use volumes_client_latest. if CONF.volume_feature_enabled.api_v1: cls.volumes_client = cls.os_primary.volumes_client cls.snapshots_client = cls.os_primary.snapshots_client cls.volume_types_client = cls.os_primary.volume_v1.TypesClient() else: cls.volumes_client = cls.os_primary.volumes_client_latest cls.snapshots_client = cls.os_primary.snapshots_client_latest if CONF.volume_feature_enabled.api_v2: cls.volume_types_client = cls.os_primary.volume_v2.TypesClient() else if CONF.volume_feature_enabled.api_v3: cls.volume_types_client = cls.os_primary.volume_v3.TypesClient() # from /usr/lib/python2.7/site-packages/barbican_tempest_plugin/tests/scenario/barbican_manager.py#83 if CONF.compute_feature_enabled.attach_encrypted_volume: if CONF.volume_feature_enabled.api_v2: cls.admin_volume_types_client =\ os_adm.volume_types_v2_client cls.admin_encryption_types_client =\ os_adm.encryption_types_v2_client else: cls.admin_volume_types_client =\ os_adm.volume_types_client cls.admin_encryption_types_client =\ os_adm.encryption_types_client # Should be using same volume type and encryption types # clients for both v2 and v3 apis if CONF.compute_feature_enabled.attach_encrypted_volume: if (CONF.volume_feature_enabled.api_v2 or CONF.volume_feature_enabled.api_v3): cls.admin_volume_types_client =\ os_adm.volume_types_v2_client cls.admin_encryption_types_client =\ os_adm.encryption_types_v2_client else: cls.admin_volume_types_client =\ os_adm.volume_types_client cls.admin_encryption_types_client =\ os_adm.encryption_types_client I looked upstream and it appears master branch of the barbican tempest plugin has also been updated to work with latest tempest client code, the barbican package just needs an update I think.
commit c9f0b5d46b17bc55182489150bd6cc6a0399d204 fixes this in the master branch upstream. It looks like the queens spec file is tied to a specific commit. We need to just update this to latest. https://github.com/rdo-packages/barbican-tempest-plugin-distgit/blob/queens-rdo/python-barbican-tests-tempest.spec Rocky, Stein and Master are not tied to a specific version. There are no branches for different releases. So, yeah, just need to update the commit hash to a later version.
Has this fix been released in zstream?
The fix is targeted to be shipped as part of the next z-stream.
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2020:0769