fix(ci): type qr dashboard runtime mocks

This commit is contained in:
Peter Steinberger
2026-04-03 21:57:24 +01:00
parent 1c5a4d01c9
commit 8343a11a6b

View File

@@ -18,12 +18,12 @@ type CliRuntimeEnv = RuntimeEnv & {
const runtimeLogs: string[] = [];
const runtimeErrors: string[] = [];
const runtime = vi.hoisted<CliRuntimeEnv>(() => ({
log: (...args: unknown[]) => {
log: vi.fn((...args: unknown[]) => {
runtimeLogs.push(args.map(String).join(" "));
},
error: (...args: unknown[]) => {
}),
error: vi.fn((...args: unknown[]) => {
runtimeErrors.push(args.map(String).join(" "));
},
}),
exit: vi.fn<(code: number) => void>(),
}));