test: clean up lint warnings

This commit is contained in:
Peter Steinberger
2026-01-10 16:16:55 +01:00
parent 53a0c966a5
commit 78532d76bd
2 changed files with 5 additions and 8 deletions

View File

@@ -2,12 +2,9 @@ import { describe, expect, it } from "vitest";
import { formatHealthCheckFailure } from "./health-format.js"; import { formatHealthCheckFailure } from "./health-format.js";
const stripAnsi = (input: string) => const ansiEscape = String.fromCharCode(27);
input.replace( const ansiRegex = new RegExp(`${ansiEscape}\\[[0-9;]*m`, "g");
// biome-ignore lint/suspicious/noControlCharactersInRegex: strip ANSI escape sequences const stripAnsi = (input: string) => input.replace(ansiRegex, "");
/\u001b\[[0-9;]*m/g,
"",
);
describe("formatHealthCheckFailure", () => { describe("formatHealthCheckFailure", () => {
it("keeps non-rich output stable", () => { it("keeps non-rich output stable", () => {

View File

@@ -209,9 +209,9 @@ describeLive("gateway live (dev agent, profile keys)", () => {
const nextCfg = { const nextCfg = {
...cfg, ...cfg,
agents: { agents: {
...(cfg.agents ?? {}), ...cfg.agents,
defaults: { defaults: {
...(cfg.agents?.defaults ?? {}), ...cfg.agents?.defaults,
models: Object.fromEntries( models: Object.fromEntries(
candidates.map((m) => [`${m.provider}/${m.id}`, {}]), candidates.map((m) => [`${m.provider}/${m.id}`, {}]),
), ),