updated tests
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
"""Root conftest for all tests."""
|
||||
|
||||
import os
|
||||
import tempfile
|
||||
import pytest
|
||||
|
||||
|
||||
def pytest_configure(config: pytest.Config) -> None:
|
||||
"""Configure pytest environment before any imports happen."""
|
||||
# Set DATA_DIR before any modules are imported
|
||||
if "DATA_DIR" not in os.environ:
|
||||
tmpdir = tempfile.mkdtemp(prefix="baby_monitor_test_")
|
||||
os.environ["DATA_DIR"] = tmpdir
|
||||
os.environ["ENVIRONMENT"] = "development"
|
||||
Reference in New Issue
Block a user