Skip to content

Commit 4b9fd24

Browse files
committed
fix for windows test...hopefully
1 parent 01bfe1a commit 4b9fd24

File tree

1 file changed

+18
-1
lines changed

1 file changed

+18
-1
lines changed

src/core/prompts/__tests__/custom-system-prompt.spec.ts

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,23 @@ vi.mock("../../../utils/fs", () => ({
3939
createDirectoriesForFile: vi.fn().mockResolvedValue([]),
4040
}))
4141

42+
vi.mock("../../../services/code-index/manager", () => ({
43+
CodeIndexManager: {
44+
getInstance: vi.fn().mockReturnValue({
45+
isFeatureEnabled: false,
46+
isFeatureConfigured: false,
47+
isInitialized: false,
48+
getCurrentStatus: vi.fn().mockReturnValue({
49+
systemStatus: "Standby",
50+
message: "",
51+
}),
52+
searchIndex: vi.fn().mockResolvedValue([]),
53+
dispose: vi.fn(),
54+
}),
55+
disposeAll: vi.fn(),
56+
},
57+
}))
58+
4259
import { SYSTEM_PROMPT } from "../system"
4360
import { defaultModeSlug, modes } from "../../../shared/modes"
4461
import * as vscode from "vscode"
@@ -62,7 +79,7 @@ const mockContext = {
6279
globalState: {
6380
get: () => undefined,
6481
update: () => Promise.resolve(),
65-
setKeysForSync: () => {},
82+
setKeysForSync: () => { },
6683
},
6784
extensionUri: { fsPath: "mock/extension/path" },
6885
globalStorageUri: { fsPath: "mock/settings/path" },

0 commit comments

Comments
 (0)