Files
geointel/backend/tests/test_rotate_belgium_building_holdouts.py
Jens faeb58ef6d
GeoIntel release gates / Compile, test, contracts and builds (push) Successful in 1m49s
GeoIntel release gates / Python and npm vulnerability policy (push) Successful in 21s
GeoIntel release gates / Production AI image, SBOM and container scan (push) Successful in 5m39s
GeoIntel release gates / Deploy exact gated revision to Unraid (push) Failing after 58m43s
Initial public release
2026-08-31 21:56:53 +02:00

22 lines
705 B
Python

from __future__ import annotations
import importlib.util
from pathlib import Path
import pytest
SCRIPT = Path(__file__).parents[2] / "scripts" / "rotate_belgium_building_holdouts.py"
SPEC = importlib.util.spec_from_file_location("rotate_building_holdouts", SCRIPT)
assert SPEC and SPEC.loader
MODULE = importlib.util.module_from_spec(SPEC)
SPEC.loader.exec_module(MODULE)
def test_rotated_corpus_version_is_explicit_and_canonical() -> None:
assert MODULE.validate_dataset_version("building-be-v31-rotated-holdouts-r1") == (
"building-be-v31-rotated-holdouts-r1"
)
with pytest.raises(ValueError, match="canonical slug"):
MODULE.validate_dataset_version("Building BE v31")