1
0
mirror of https://github.com/immich-app/immich.git synced 2024-12-13 11:54:52 +02:00
immich/server/test/repositories/asset.repository.mock.ts
Jason Rasmussen 454737ca79
refactor(server): update asset endpoint (#3973)
* refactor(server): update asset

* chore: open api
2023-09-04 22:25:31 -04:00

25 lines
746 B
TypeScript

import { IAssetRepository } from '@app/domain';
export const newAssetRepositoryMock = (): jest.Mocked<IAssetRepository> => {
return {
upsertExif: jest.fn(),
getByDate: jest.fn(),
getByIds: jest.fn().mockResolvedValue([]),
getByAlbumId: jest.fn(),
getByUserId: jest.fn(),
getWithout: jest.fn(),
getWith: jest.fn(),
getFirstAssetForAlbumId: jest.fn(),
getLastUpdatedAssetForAlbumId: jest.fn(),
getAll: jest.fn().mockResolvedValue({ items: [], hasNextPage: false }),
updateAll: jest.fn(),
deleteAll: jest.fn(),
save: jest.fn(),
findLivePhotoMatch: jest.fn(),
getMapMarkers: jest.fn(),
getStatistics: jest.fn(),
getByTimeBucket: jest.fn(),
getTimeBuckets: jest.fn(),
};
};