From b1e6beb919699d2d9f031136695bd788fa019bcf Mon Sep 17 00:00:00 2001 From: Alex Kavanagh Date: Fri, 20 Sep 2019 15:18:10 +0200 Subject: [PATCH] Further work to get keystone specific test to work --- zaza/openstack/charm_tests/keystone/__init__.py | 2 +- zaza/openstack/charm_tests/policyd/tests.py | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/zaza/openstack/charm_tests/keystone/__init__.py b/zaza/openstack/charm_tests/keystone/__init__.py index 2f6dd1f..e244e16 100644 --- a/zaza/openstack/charm_tests/keystone/__init__.py +++ b/zaza/openstack/charm_tests/keystone/__init__.py @@ -30,7 +30,7 @@ class BaseKeystoneTest(test_utils.OpenStackBaseTest): """Base for Keystone charm tests.""" @classmethod - def setUpClass(cls): + def setUpClass(cls, application_name=None): """Run class setup for running Keystone charm operation tests.""" super(BaseKeystoneTest, cls).setUpClass(application_name='keystone') # Check if we are related to Vault TLS certificates diff --git a/zaza/openstack/charm_tests/policyd/tests.py b/zaza/openstack/charm_tests/policyd/tests.py index 2b85c97..5605bc0 100644 --- a/zaza/openstack/charm_tests/policyd/tests.py +++ b/zaza/openstack/charm_tests/policyd/tests.py @@ -92,7 +92,7 @@ class PolicydTest(object): zaza_model.block_until_wl_status_info_starts_with( self.application_name, "PO:", negate_match=True) - def test_policyd_good_yaml(self): + def test_001_policyd_good_yaml(self): # Test that the policyd with a good zipped yaml file puts the yaml file # in the right directory good = { @@ -151,7 +151,9 @@ class KeystonePolicydTest(PolicydTest, super(KeystonePolicydTest, cls).setUpClass(application_name) def test_disable_service(self): - self._set_policy_with({"identity:get_auth_domains": "!"}) + logging.info("Doing policyd override to disable listing domains") + self._set_policy_with( + {'rule.yaml': "{'identity:get_auth_domains': '!'}"}) with self.config_change( {'preferred-api-version': self.default_api_version}, {'preferred-api-version': '3'},