Проект разделен на два репозитория
This commit is contained in:
@@ -0,0 +1,20 @@
|
||||
from __future__ import annotations
|
||||
|
||||
from pathlib import Path
|
||||
|
||||
import pytest
|
||||
import yaml
|
||||
|
||||
from app.config import ActiveConfig, validate_config
|
||||
|
||||
|
||||
@pytest.fixture
|
||||
def artifacts() -> Path:
|
||||
return Path(__file__).parents[1] / "app" / "artifacts"
|
||||
|
||||
|
||||
@pytest.fixture
|
||||
def active_config(artifacts: Path) -> ActiveConfig:
|
||||
document = yaml.safe_load((artifacts / "seed-config.yaml").read_text(encoding="utf-8"))
|
||||
rules, detector, _ = validate_config(document, artifacts)
|
||||
return ActiveConfig(1, document, rules, detector)
|
||||
Reference in New Issue
Block a user