initial commit

This commit is contained in:
Daniel 2023-11-21 15:20:43 +01:00
parent b84bd80842
commit 9411fe61ee
11 changed files with 272 additions and 1 deletions

View file

@ -0,0 +1,20 @@
from pathlib import Path
import pytest
from dotenv import dotenv_values
def pytest_addoption(parser):
parser.addoption(
"--env_file_path",
action="store",
)
@pytest.fixture
def config(request):
dotenv_path = request.config.getoption("--env_file_path")
dotenv_path = Path(dotenv_path)
assert dotenv_path.is_file()
config = dotenv_values(dotenv_path)
return config