From 75ad5757528491616f7f4e596bb9f6b152944d99 Mon Sep 17 00:00:00 2001 From: Rob Crittenden Date: Mon, 23 Nov 2020 18:23:33 -0500 Subject: [PATCH] ipatests: honor class inheritance in TestACMEwithExternalCA TestACMEwithExternalCA subclasses TestACME which subclasses CALessBase. CALessBase is necessary to generate the certificates for the test_third_party_certs() test. This means that the TestACME install classmethod needs to be called by its subclasses. But the install actually does the installation of the servers as well so needs to be aborted at that point in the case of a subclass. https://pagure.io/freeipa/issue/8581 Signed-off-by: Rob Crittenden Reviewed-By: Florence Blanc-Renaud Reviewed-By: Mohammad Rizwan Reviewed-By: Armando Neto --- ipatests/test_integration/test_acme.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/ipatests/test_integration/test_acme.py b/ipatests/test_integration/test_acme.py index 6998cbf87..3fd322f05 100644 --- a/ipatests/test_integration/test_acme.py +++ b/ipatests/test_integration/test_acme.py @@ -109,6 +109,10 @@ class TestACME(CALessBase): # install packages before client install in case of IPA DNS problems cls.prepare_acme_client() + # Each subclass handles its own server installation procedure + if cls.__name__ != 'TestACME': + return + tasks.install_master(cls.master, setup_dns=True) tasks.install_client(cls.master, cls.clients[0]) @@ -510,8 +514,7 @@ class TestACMEwithExternalCA(TestACME): @classmethod def install(cls, mh): - - cls.prepare_acme_client() + super(TestACMEwithExternalCA, cls).install(mh) # install master with external-ca result = install_server_external_ca_step1(cls.master)