mirror of
https://github.com/immich-app/immich.git
synced 2025-01-11 06:10:28 +02:00
11 lines
381 B
TypeScript
11 lines
381 B
TypeScript
|
import { IDatabaseRepository, Version } from '@app/domain';
|
||
|
|
||
|
export const newDatabaseRepositoryMock = (): jest.Mocked<IDatabaseRepository> => {
|
||
|
return {
|
||
|
getExtensionVersion: jest.fn(),
|
||
|
getPostgresVersion: jest.fn().mockResolvedValue(new Version(14, 0, 0)),
|
||
|
createExtension: jest.fn().mockImplementation(() => Promise.resolve()),
|
||
|
runMigrations: jest.fn(),
|
||
|
};
|
||
|
};
|