Commit 4bb51ac0 authored by lukas.burgey's avatar lukas.burgey
Browse files

Add teardown to tests

parent b3d8d1f6
Pipeline #81757 failed with stage
in 1 minute and 46 seconds
......@@ -88,12 +88,30 @@ class BaseTestCase(TestCase):
vos=[cls.group_two],
)
SSHPublicKey(
cls.key = SSHPublicKey(
name=cls.TEST_NAME,
key=cls.TEST_KEY,
user=cls.user,
).save()
@classmethod
def tearDownClass(cls):
# delete in reverse order
for member in [
cls.key,
cls.service_one,
cls.service_two_a,
cls.service_two_b,
cls.site,
cls.site2,
cls.user,
cls.group_none,
cls.group_one,
cls.group_two,
cls.idp,
]:
member.delete()
# the user is logged in using session authentication
class LoggedInTest(BaseTestCase):
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment