mock settings fetch in test

This commit is contained in:
DaKheera47 2026-01-26 11:05:02 +00:00
parent fdb7c5f4b3
commit b432691414

View File

@ -4,6 +4,11 @@ import { pickProjectIdsForJob } from "./projectSelection.js";
import { scoreJobSuitability } from "./scorer.js";
// --- Mocks ---
vi.mock("../repositories/settings.js", () => ({
getSetting: vi.fn().mockResolvedValue(null),
getAllSettings: vi.fn().mockResolvedValue({}),
}));
// We need to mock 'fetch' globally for these tests
const globalFetch = global.fetch;