From c5e1d1ca131a0c98bbfb6ff2a4a07e3b8f0a8408 Mon Sep 17 00:00:00 2001 From: Christian Poessinger Date: Mon, 25 Apr 2022 18:51:26 +0200 Subject: smoketest: pki: use setUpClass() over setUp() --- smoketest/scripts/cli/test_pki.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/smoketest/scripts/cli/test_pki.py b/smoketest/scripts/cli/test_pki.py index 45a4bd61e..e92123dbc 100755 --- a/smoketest/scripts/cli/test_pki.py +++ b/smoketest/scripts/cli/test_pki.py @@ -129,8 +129,13 @@ xGsJxVHfSKeooUQn6q76sg== """ class TestPKI(VyOSUnitTestSHIM.TestCase): - def setUp(self): - self.cli_delete(base_path) + @classmethod + def setUpClass(cls): + super(TestPKI, cls).setUpClass() + + # ensure we can also run this test on a live system - so lets clean + # out the current configuration :) + cls.cli_delete(cls, base_path) def tearDown(self): self.cli_delete(base_path) -- cgit v1.2.3