Model/tests/scripts
Daniel Roth ae1da26558 Move the PasHub fetcher into the DDD layer structure 🟪
The service was the last one living wholly under backend/. It now follows
the same layering as abri and the other newer services:

  domain/pashub_fetcher/          core file classification, subfolders
  infrastructure/pashub_fetcher/  PasHub client, token getter, wire DTOs
  orchestration/                  PashubFetcherOrchestrator (was PashubService)
  applications/pashub_fetcher/    lambda handler, trigger request, dev tooling

core_files.py is split along the layer boundary: the domain module keeps the
filename/evidence-category classification rules and no longer imports
infrastructure.postgres, while the CoreFiles -> FileTypeEnum translation moves
to infrastructure/pashub_fetcher/core_file_types.py.

Tests move into the tests/ tree by layer. Note this puts them in the only
suite CI currently runs (unit_tests.yml is disabled), so these 73 tests now
execute on PRs for the first time; they were previously reachable only via
the legacy pytest.ini testpaths.

sharepoint_renamer's image now copies just domain/pashub_fetcher/ rather than
the whole service, since SharepointSubfolders is all it needed.

Behaviour is unchanged. tests/ goes 9927 -> 10000 passed (+73, exactly the
tests that moved in); the legacy suite keeps its same 17 pre-existing failures
and 11 errors. tests/test_lambda_packaging.py confirms both changed
Dockerfiles still copy their handler's full import closure.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-22 13:35:54 +00:00
..
__init__.py Rename files in subfolders too 2026-06-12 16:04:19 +00:00
test_audit_anomalies.py Flag works bought for no real SAP gain 🟥 2026-07-21 15:53:59 +00:00
test_expired_prediction_pairs_harness.py The historic roof description conditions the cohort by form family 🟩 2026-07-06 12:05:56 +00:00
test_neighbour_divergence.py neighbour_divergence: key cohorts on main-heating fuel 2026-07-01 14:24:31 +00:00
test_null_predicted_lodged_performance.py Backfill the phantom Lodged Performance on predicted Properties to NULL 🟩 2026-06-30 22:17:57 +00:00
test_reclassify_flat_roof_thickness.py Re-classify flat-roof overrides with a known depth onto their thickness member 🟩 2026-07-01 10:19:09 +00:00
test_reclassify_heating_overrides.py One-time script to re-classify stale heating overrides 2026-06-30 20:30:59 +00:00
test_reclassify_main_heating.py Reclassify electric-underfloor overrides via the generalized main-heating reclassify 🟩 2026-07-01 16:51:22 +00:00
test_reclassify_mixed_glazing.py Re-classify aggregate-mix glazing overrides flattened to Double onto MIXED 🟩 2026-07-01 11:09:42 +00:00
test_reclassify_party_ceiling_roofs.py Re-classify party-ceiling roof overrides mis-read as external roofs 🟩 2026-07-01 09:46:01 +00:00
test_reclassify_water_heating.py Assert every water-heating reclassify target round-trips to a resolvable archetype 🟩 2026-07-01 14:02:18 +00:00
test_rename_sharepoint_files.py Move the PasHub fetcher into the DDD layer structure 🟪 2026-07-22 13:35:54 +00:00