From ad95ed649f4e217bfd164bb98446b3d97805c2f1 Mon Sep 17 00:00:00 2001 From: Daniel Date: Fri, 24 Nov 2023 17:51:13 +0100 Subject: [PATCH] cleanup --- src/conftest.py | 15 +++------------ 1 file changed, 3 insertions(+), 12 deletions(-) diff --git a/src/conftest.py b/src/conftest.py index 992f497..ddb9885 100644 --- a/src/conftest.py +++ b/src/conftest.py @@ -9,17 +9,9 @@ from pathlib import Path import pytest from dotenv import dotenv_values -from icecream import ic -from playwright.sync_api import BrowserContext from src.dirmanager import DirManager -# pytest_plugins = [ -# "setup.setup_authentik", -# "src.tests_authentik.authentik_plugin" -# ] - - TIMEOUT = 5000 @@ -56,7 +48,7 @@ def dotenv_config(request) -> dict[str, str]: assert dotenv_path is not None, "required pytest command line argument not given" dotenv_path = Path(dotenv_path) assert dotenv_path.is_file() - return dotenv_values(dotenv_path) + return dotenv_values(dotenv_path) # type: ignore @pytest.fixture(scope="session", autouse=True) @@ -75,11 +67,10 @@ def RESULTS(dirmanager) -> Path: return dirmanager.RESULTS -# log failed tests - - @pytest.hookimpl(tryfirst=True, hookwrapper=True) def pytest_runtest_makereport(item, call): + """saves traceback when test fails""" + # execute all other hooks to obtain the report object outcome = yield rep = outcome.get_result()