refactor for independent test dirs #7

Merged
dan merged 49 commits from independent-test-dirs into dev 2023-12-05 21:41:46 +01:00
4 changed files with 4 additions and 6 deletions
Showing only changes of commit 24dae132a1 - Show all commits

View file

@ -22,7 +22,7 @@ class Runner:
setups: list[Test] = []
tests: list[Test] = []
cleanups: list[Test] = []
dependencies: list[type["Runner"]] = []
dependencies: list[str] = []
prevent_skip = False
def __init__(self, dotenv_path: Path, output_dir: Path, session_id: str):

View file

@ -12,7 +12,7 @@ class RunnerDemo(Runner):
# RunnerDemo will only execute, when setup_authentik.py has finished successfully.
# For example, setup_authentik.py generates session states, that can be used as fixtures
# that can be loaded from fixtures_authentik.py
dependencies: list[type["Runner"]] = [RunnerAuthentik]
dependencies: list[str] = ["authentik"]
# todo: update these comments
# Filename of Demo setup. If defined, it will run 1st by executing pytest

View file

@ -1,5 +1,4 @@
from src.runner import Runner, Test
from src.tests_authentik.runner_authentik import RunnerAuthentik
def condition_always_false(dotenv_config: dict[str, str]) -> bool:
@ -9,7 +8,7 @@ def condition_always_false(dotenv_config: dict[str, str]) -> bool:
class RunnerNextcloud(Runner):
name: str = "nextcloud"
test_dir_name: str = "tests_nextcloud"
dependencies = [RunnerAuthentik]
dependencies = ["authentik"]
setups = [Test(test_file="setup_nextcloud.py", prevent_skip=False)]
tests = [
Test(test_file="tests_nextcloud.py", prevent_skip=True),

View file

@ -1,5 +1,4 @@
from src.runner import Runner, Test
from src.tests_authentik.runner_authentik import RunnerAuthentik
def condition_always_true(dotenv_config: dict[str, str]) -> bool:
@ -20,7 +19,7 @@ def condition_has_locale(dotenv_config: dict[str, str]) -> bool:
class RunnerWordpress(Runner):
name = "wordpress"
test_dir_name = "tests_wordpress"
dependencies: list[type[Runner]] = [RunnerAuthentik]
dependencies = ["authentik"]
setups = [Test(test_file="setup_wordpress.py")]
tests = [
Test(test_file="test_wordpress.py"),