From 299fae65dbc561ad766cef3da2a3b2c2e0f84ba4 Mon Sep 17 00:00:00 2001 From: Liam Young Date: Mon, 12 Oct 2020 12:03:44 +0000 Subject: [PATCH] Fix test runs with no charm_name Fix z-o-t so that tests that specify an application name can be run irrespective of whether the charm_name has been set in tests.yaml. Closes issue #442 --- zaza/openstack/charm_tests/test_utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/zaza/openstack/charm_tests/test_utils.py b/zaza/openstack/charm_tests/test_utils.py index 74b76b27b..493a86897 100644 --- a/zaza/openstack/charm_tests/test_utils.py +++ b/zaza/openstack/charm_tests/test_utils.py @@ -127,11 +127,11 @@ def setUpClass(cls, application_name=None, model_alias=None): else: cls.model_name = model.get_juju_model() cls.test_config = lifecycle_utils.get_charm_config(fatal=False) - charm_under_test_name = cls.test_config['charm_name'] if application_name: cls.application_name = application_name else: + charm_under_test_name = cls.test_config['charm_name'] deployed_app_names = model.sync_deployed(model_name=cls.model_name) if charm_under_test_name in deployed_app_names: # There is an application named like the charm under test.