test: remove duplicate and theatrical tests (#2763)

removed the "integration with getScriptFailureGuidance" describe block
from credential-hints.test.ts. all three tests were redundant:

- "always includes setup instructions regardless of env state": tested
  for vague "setup instructions" string, already verified by the
  "when all required env vars are missing" describe block above.

- "always returns at least one line": pure existence check, already
  proven by the "when no authHint is provided" tests which assert exact
  length of 1.

- "returns more lines when authHint is provided": tests line-count
  implementation detail rather than behavior; behavior is fully covered
  by the per-scenario describe blocks.

1467 to 1464 tests. zero regressions. biome lint: 0 errors.


-- qa/dedup-scanner

Co-authored-by: spawn-qa-bot <qa@openrouter.ai>
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
A 2026-03-18 06:37:40 -07:00 committed by GitHub
parent 18a9d43133
commit 47b8bd30cc
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -128,23 +128,4 @@ describe("credentialHints", () => {
expect(joined).not.toContain("OPENROUTER_API_KEY -- not set");
});
});
describe("integration with getScriptFailureGuidance", () => {
it("always includes setup instructions regardless of env state", () => {
const hints = credentialHints("digitalocean", "DO_API_TOKEN");
const joined = hints.join("\n");
expect(joined).toContain("setup instructions");
});
it("always returns at least one line", () => {
const hints = credentialHints("sprite");
expect(hints.length).toBeGreaterThanOrEqual(1);
});
it("returns more lines when authHint is provided", () => {
const withHint = credentialHints("hetzner", "HCLOUD_TOKEN");
const withoutHint = credentialHints("hetzner");
expect(withHint.length).toBeGreaterThan(withoutHint.length);
});
});
});