We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6f7a024 commit a1bfac2Copy full SHA for a1bfac2
packages/engine/src/workers/main.test.ts
@@ -9,6 +9,14 @@ import { ReleaseStaleJob } from "../internal-jobs/release-stale-jobs";
9
import { JobBuilder } from "../job/job-builder";
10
import { runWorker, startCron } from "./main";
11
12
+const runMock = vi.fn();
13
+
14
+vi.mock("../shared-runner", () => ({
15
+ RunnerPool: vi.fn().mockImplementation(() => ({
16
+ run: runMock,
17
+ })),
18
+}));
19
20
const cronMocks = vi.hoisted(() => ({
21
schedule: vi.fn().mockReturnValue({ execute: vi.fn() }),
22
}));
0 commit comments