mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-07 23:51:23 +00:00
test: annotate harness mocks to avoid TS2742 in CI
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
import { vi } from "vitest";
|
||||
import type { MockFn } from "../test-utils/vitest-mock-fn.js";
|
||||
|
||||
export const baseConfigSnapshot = {
|
||||
path: "/tmp/openclaw.json",
|
||||
@@ -11,7 +12,13 @@ export const baseConfigSnapshot = {
|
||||
legacyIssues: [],
|
||||
};
|
||||
|
||||
export function createTestRuntime() {
|
||||
export type TestRuntime = {
|
||||
log: MockFn;
|
||||
error: MockFn;
|
||||
exit: MockFn;
|
||||
};
|
||||
|
||||
export function createTestRuntime(): TestRuntime {
|
||||
return {
|
||||
log: vi.fn(),
|
||||
error: vi.fn(),
|
||||
|
||||
Reference in New Issue
Block a user