* make it so that the actual tests can be moved anywhere, for example in abra recipe repos -> major refactoring with pytest test discovery magic * create RUNNER_DICT dynamically with importlib -> none of the tests are hardcoded, more tests can be added by placing a folder * autoload fixtures with pytest plugins * add URL fixture to navigate on web pages. Includes url parser based on python urllib to generate correct links * fix nextcloud setups and tests * add email groundwork with imbox Reviewed-on: local-it-infrastructure/e2e_tests#7 Co-authored-by: Daniel <d.brummerloh@gmail.com> Co-committed-by: Daniel <d.brummerloh@gmail.com>
25 lines
1.2 KiB
Python
25 lines
1.2 KiB
Python
from abratest.runner import Runner, Test
|
|
|
|
|
|
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.
|
|
# For example, setup_authentik.py generates session states, that can be used as fixtures
|
|
# that can be loaded from fixtures_authentik.py
|
|
dependencies: list[str] = ["authentik"]
|
|
|
|
# todo: update these comments
|
|
# Filename of Demo setup. If defined, it will run 1st by executing pytest
|
|
# Filename of Demo test. This file contains unconditional tests that will be run in any
|
|
# case. If defined, it will run 2nd by executing pytest
|
|
# this list can hold many more tests from RunnerDemo that run conditional. The condition
|
|
# and the test file can be defined by creating a ConditionalTest instance:
|
|
# ConditionalTest(condition: Callable, test_file: str)
|
|
setups: list[Test] = []
|
|
tests: list[Test] = []
|
|
cleanups: list[Test] = []
|