mirror of
https://github.com/Hestia-Homes/Model.git
synced 2026-07-27 23:35:01 +00:00
Complete the task for a void property instead of dead-lettering it 🟥
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
1bb45e2f4e
commit
00adbcd519
1 changed files with 21 additions and 0 deletions
|
|
@ -23,6 +23,7 @@ from orchestration.abri_orchestrator import (
|
|||
DealAbandonment,
|
||||
JobNoNotYetRecordedError,
|
||||
LogJobOrchestrationResult,
|
||||
PropertyReportedVoid,
|
||||
LogJobSummary,
|
||||
LogJobWriteBackError,
|
||||
TenantDataSyncResult,
|
||||
|
|
@ -426,3 +427,23 @@ def test_the_summary_records_an_abandoned_job(
|
|||
|
||||
# Assert
|
||||
assert summary == {"abandon_job": "job AC0439951 abandoned"}
|
||||
|
||||
|
||||
# --- a void property completes the flow rather than failing the task ---
|
||||
|
||||
|
||||
def test_a_void_property_completes_the_tenant_sync_instead_of_failing_the_task(
|
||||
orchestrator: FakeOrchestrator, deal_database: FakeDealDatabase
|
||||
) -> None:
|
||||
# Arrange: an empty property has no signatories, so redelivering the
|
||||
# message could only park it in the dead-letter queue.
|
||||
orchestrator.sync_outcome = PropertyReportedVoid(place_ref=PlaceRef("1007165"))
|
||||
request = _request(["sync_tenant_data"])
|
||||
|
||||
# Act
|
||||
summary = dispatch_abri_flows(request, orchestrator, deal_database)
|
||||
|
||||
# Assert
|
||||
assert summary == {
|
||||
"sync_tenant_data": "no live tenancy for place 1007165; property noted as void"
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue