Add constants.py and its test

Task: MIL-001#3
This commit is contained in:
2026-10-13 15:26:20 +08:00
parent 3db6634b15
commit a44339927c
4 changed files with 114 additions and 0 deletions
+16
View File
@@ -0,0 +1,16 @@
"""Shared pytest configuration for the weather data tests."""
from pathlib import Path
import pytest
@pytest.fixture(autouse=True)
def isolated_working_directory(tmp_path: Path, monkeypatch: pytest.MonkeyPatch) -> None:
"""Run every test in an empty temporary working directory.
The export has a default file name relative to the working directory. Without
this fixture, a test that uses the default would write into the folder pytest
was started from.
"""
monkeypatch.chdir(tmp_path)