Model/tests/domain/modelling
Khalim Conn-Kowlessar 4c0a907a54 test(modelling): Elmhurst before/after cascade pin for cavity wall (#1154)
Closes #1154 — the Package Scorer's Elmhurst cascade pin. Drives
recommend_cavity_wall on the parsed `before` Summary, scores its
Option's overlay through PackageScorer, and asserts delta 0 (abs<=1e-4
on SAP/CO2/PE) vs the calculator's score on the re-lodged `after`
Summary.

Key finding: the handover's stated parser gate (parse_site_notes_pdf
throwing 'Manufacturer' on cert 001431) does NOT block these pins. The
Elmhurst recommendation Summaries route cleanly through the same
ElmhurstSiteNotesExtractor + EpcPropertyDataMapper chain the worksheet
e2e fixtures use (_elmhurst_worksheet_001431.build_epc). The Textract
path's window bug is unrelated and unused here.

The before→after field change is exactly wall_insulation_type 4
(uninsulated) → 2 (filled cavity), which is precisely the overlay
recommend_cavity_wall emits; the cascade closes at delta 0.000000 on
all three metrics. Before/after Summaries mirrored into
tests/domain/modelling/fixtures/ so the pin does not depend on the
unstaged workspace.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-03 09:36:53 +00:00
..
fixtures test(modelling): Elmhurst before/after cascade pin for cavity wall (#1154) 2026-06-03 09:36:53 +00:00
__init__.py feat(modelling): Overlay Applicator folds EpcSimulation onto EpcPropertyData 2026-06-02 22:13:51 +00:00
_elmhurst_recommendation.py test(modelling): Elmhurst before/after cascade pin for cavity wall (#1154) 2026-06-03 09:36:53 +00:00
test_elmhurst_cascade_pins.py test(modelling): Elmhurst before/after cascade pin for cavity wall (#1154) 2026-06-03 09:36:53 +00:00
test_floor_recommendation.py feat(modelling): floor Recommendation Generator + ground-floor-area geometry 2026-06-03 09:12:29 +00:00
test_overlay_applicator.py feat(modelling): Overlay Applicator folds EpcSimulation onto EpcPropertyData 2026-06-02 22:13:51 +00:00
test_package_scorer.py feat(modelling): Package Scorer — compose overlays + score on the calculator 2026-06-03 08:41:30 +00:00
test_roof_recommendation.py feat(modelling): roof (loft) Recommendation Generator + roof-area geometry 2026-06-03 09:05:38 +00:00
test_scoring.py feat(modelling): per-measure scoring — marginal cascade + per-Option signal (#1156) 2026-06-03 08:50:49 +00:00
test_wall_recommendation.py feat(modelling): price the cavity Option from area x Product — closes #1155 2026-06-03 08:35:52 +00:00