fix(multiplayer): publish stalled allocation recovery

This commit is contained in:
Josh Creek
2026-09-01 18:19:28 +01:00
parent 7c044b7094
commit 76c1c3d600
4 changed files with 47 additions and 4 deletions
@@ -14,11 +14,17 @@ func TestExpireStalledAllocationsSQLFencesAndRequeuesWithoutPenalty(t *testing.T
"SET state = 'FAILED'",
"SET participation_active = FALSE",
"SET state = 'QUEUED'",
"INSERT INTO outbox",
"'state_changed'",
"'stalled-allocation:'",
} {
if !strings.Contains(ExpireStalledAllocationsSQL, fragment) {
t.Fatalf("ExpireStalledAllocationsSQL missing fragment %q:\n%s", fragment, ExpireStalledAllocationsSQL)
}
}
if !strings.Contains(ExpireStalledAllocationsSQL, "occurred_at', $4") {
t.Fatalf("stalled allocation event timestamp is not bound")
}
}
func TestExpireStalledAllocationsRejectsInvalidArgumentsWithoutDatabase(t *testing.T) {