fully remove test_dir_name
This commit is contained in:
parent
65328d9816
commit
e415b8a16a
5 changed files with 4 additions and 6 deletions
|
|
@ -19,7 +19,6 @@ class Test:
|
|||
|
||||
class Runner:
|
||||
name: str = ""
|
||||
test_dir_name: str = ""
|
||||
setups: list[Test] = []
|
||||
tests: list[Test] = []
|
||||
cleanups: list[Test] = []
|
||||
|
|
@ -69,7 +68,10 @@ class Runner:
|
|||
# condition_met: true / false
|
||||
|
||||
identifier_string = self.combine_names(self.name, test.test_file)
|
||||
full_test_path = self.DIR.RECIPES / self.name / self.test_dir_name / test.test_file
|
||||
|
||||
results = list(self.DIR.RECIPES.rglob(test.test_file))
|
||||
assert len(results) == 1, f"{test.test_file} should exist exactly 1 time, but found {len(results)} times"
|
||||
full_test_path = results[0]
|
||||
|
||||
# check if test aleady passed
|
||||
if self._is_test_passed(identifier_string, remove_existing=True):
|
||||
|
|
|
|||
|
|
@ -11,6 +11,5 @@ def condition_always_false(dotenv_config: dict[str, str]) -> bool:
|
|||
|
||||
class RunnerAuthentik(Runner):
|
||||
name = "authentik"
|
||||
test_dir_name = "tests_authentik"
|
||||
setups = [Test(test_file="setup_authentik.py")]
|
||||
# tests = [Test(test_file="test_authentik_dummy.py")]
|
||||
|
|
|
|||
|
|
@ -5,7 +5,6 @@ class RunnerDemo(Runner):
|
|||
"""Every env file has a corresponding runner class"""
|
||||
|
||||
name: str = "demo" # name of the test, used for logging / output naming
|
||||
test_dir_name: str = "tests_demo" # dir name holding all tests related to RunnerDemo
|
||||
|
||||
# this indicates that tests from RunnerDemo depend on the setup from RunnerAuthentik.
|
||||
# RunnerDemo will only execute, when setup_authentik.py has finished successfully.
|
||||
|
|
|
|||
|
|
@ -7,7 +7,6 @@ def condition_always_false(dotenv_config: dict[str, str]) -> bool:
|
|||
|
||||
class RunnerNextcloud(Runner):
|
||||
name: str = "nextcloud"
|
||||
test_dir_name: str = "tests_nextcloud"
|
||||
dependencies = ["authentik"]
|
||||
setups = [Test(test_file="setup_nextcloud.py", prevent_skip=False)]
|
||||
tests = [
|
||||
|
|
|
|||
|
|
@ -18,7 +18,6 @@ def condition_has_locale(dotenv_config: dict[str, str]) -> bool:
|
|||
|
||||
class RunnerWordpress(Runner):
|
||||
name = "wordpress"
|
||||
test_dir_name = "tests_wordpress"
|
||||
dependencies = ["authentik"]
|
||||
setups = [Test(test_file="setup_wordpress.py")]
|
||||
tests = [
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue