MCPcopy Create free account
hub / github.com/callumalpass/tasknotes / createPlugin

Function createPlugin

tests/unit/ui/taskCardState.test.ts:20–38  ·  view source on GitHub ↗
(overrides: Partial<TaskNotesPlugin> = {})

Source from the content-addressed store, hash-verified

18}
19
20function createPlugin(overrides: Partial<TaskNotesPlugin> = {}): TaskNotesPlugin {
21 return {
22 settings: {
23 showCompletedTaskStrikethrough: true,
24 subtaskChevronPosition: "right",
25 },
26 statusManager: {
27 getCompletedStatuses: jest.fn(() => ["done"]),
28 isCompletedStatus: jest.fn((status: string) => status === "done"),
29 },
30 getActiveTimeSession: jest.fn(() => null),
31 app: {
32 metadataCache: {
33 getCache: jest.fn(() => null),
34 },
35 },
36 ...overrides,
37 } as unknown as TaskNotesPlugin;
38}
39
40describe("taskCardState", () => {
41 beforeEach(() => {

Callers 2

Calls

no outgoing calls

Tested by

no test coverage detected