mirror of
https://github.com/diegosouzapw/OmniRoute.git
synced 2026-08-26 17:12:27 +03:00
test(claude-web): anchor on the alias wiring, not on how the map builds it (#11585)
Merged via /merge-batch (lote 2026-08-26, v3.8.51). Boarded no worktree combinado junto com outras ~30 PRs; validação única: typecheck/complexity/cognitive-complexity/changelog-integrity verdes, file-size rebaseado onde necessário (crescimento legítimo), lint com os mesmos 228 achados pré-existentes confirmados via sonda contra o tip puro (não introduzidos por este lote), e ~370 testes focados (unit + vitest) passando. Obrigado pela contribuição.
This commit is contained in:
@@ -0,0 +1 @@
|
||||
- **test(claude-web):** the Claude Web transport test's barrel anchors no longer pin the exact construction spelling. #11421 made the executor map lazy, so `/"claude-web": new ClaudeWebExecutor\(\)/` stopped matching and the test went red on `release/v3.8.51` itself — a base-red gate every open PR inherited. The anchors now match the alias key and the class name and tolerate either spelling in between, and were checked to still fail when an alias is genuinely repointed at another executor ([#11585](https://github.com/diegosouzapw/OmniRoute/pull/11585))
|
||||
@@ -407,7 +407,12 @@ describe("Claude Web executor transport orchestration", () => {
|
||||
assert.match(executorSource, /export class ClaudeWebExecutor extends BaseExecutor/);
|
||||
assert.doesNotMatch(executorSource, /claudeTurnstileSolver|getCfClearanceToken|tryBackedChat/);
|
||||
assert.doesNotMatch(indexSource, /ClaudeWebWithAutoRefresh/);
|
||||
assert.match(indexSource, /"claude-web": new ClaudeWebExecutor\(\)/);
|
||||
assert.match(indexSource, /"cw-web": new ClaudeWebExecutor\(\)/);
|
||||
// Both aliases still resolve to ClaudeWebExecutor. Matched on the alias key
|
||||
// and the class name rather than the exact construction spelling: #11421 made
|
||||
// the map lazy (`() => import(…).then((m) => new m.ClaudeWebExecutor())`), and
|
||||
// an anchor pinned to `new ClaudeWebExecutor()` went red for a change that
|
||||
// never touched the wiring this test is here to guard.
|
||||
assert.match(indexSource, /"claude-web":.*ClaudeWebExecutor/);
|
||||
assert.match(indexSource, /"cw-web":.*ClaudeWebExecutor/);
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user