mirror of
https://github.com/Hestia-Homes/Model.git
synced 2026-07-12 13:29:04 +00:00
Adds the file-backed Product catalogue — the stopgap source for costs the ETL does not yet supply, behind the same ProductRepository port as ProductPostgresRepository. The JSON file maps each Measure Type to its fully-loaded unit cost; the per-Measure-Type contingency is joined from config (not stored in the file), so config stays the single source of truth for contingency — mirroring the Postgres repo's mapping. Strict-raises (ValueError) on an absent measure type, a non-object entry, or a missing/non-numeric unit_cost_per_m2, matching the repo-wide strict-no-silent-default convention. tmp_path-backed tests, no DB fixture needed. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| __init__.py | ||
| test_product_json_repository.py | ||
| test_product_postgres_repository.py | ||