From 5199f464c10c8ac72103526c2c334f77ad8d0a68 Mon Sep 17 00:00:00 2001 From: diegosouzapw Date: Sat, 8 Aug 2026 08:44:52 -0300 Subject: [PATCH] fix(combo): align combo-routing tests with #9630 pre-dispatch skip contract #9630 (976d670ff3) intentionally changed the pre-dispatch skip behavior: when recordedAttempts === 0 (all targets filtered before any dispatch), handleComboChat now returns 503 ALL_TARGETS_SKIPPED instead of the misleading ALL_ACCOUNTS_INACTIVE. The two combo-routing-engine tests covering the 'every target skipped before execution' scenario still asserted the old code. Align both assertions to ALL_TARGETS_SKIPPED (the tests still verify the 503 + meaningful error code). --- tests/unit/combo-routing-engine.test.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/unit/combo-routing-engine.test.ts b/tests/unit/combo-routing-engine.test.ts index 42cf4d03ef..e3f71e8052 100644 --- a/tests/unit/combo-routing-engine.test.ts +++ b/tests/unit/combo-routing-engine.test.ts @@ -2318,7 +2318,7 @@ test("handleComboChat returns a 503 when every model is unavailable before execu const payload = (await result.json()) as any; assert.equal(result.status, 503); - assert.equal(payload.error.code, "ALL_ACCOUNTS_INACTIVE"); + assert.equal(payload.error.code, "ALL_TARGETS_SKIPPED"); }); test("handleComboChat treats provider circuit breaker responses as ordinary target failures", async () => { @@ -2847,7 +2847,7 @@ test("handleComboChat round-robin resolves nested combos and returns inactive wh const payload = (await result.json()) as any; assert.equal(result.status, 503); - assert.equal(payload.error.code, "ALL_ACCOUNTS_INACTIVE"); + assert.equal(payload.error.code, "ALL_TARGETS_SKIPPED"); }); test("handleComboChat round-robin treats provider circuit breaker responses as ordinary target failures", async () => {