immich/server/libs/domain/test/job.repository.mock.ts

13 lines
327 B
TypeScript
Raw Normal View History

import { IJobRepository } from '../src';
export const newJobRepositoryMock = (): jest.Mocked<IJobRepository> => {
return {
empty: jest.fn(),
pause: jest.fn(),
resume: jest.fn(),
queue: jest.fn().mockImplementation(() => Promise.resolve()),
getQueueStatus: jest.fn(),
getJobCounts: jest.fn(),
};
};