2024-03-21 12:59:49 +01:00
|
|
|
import { IMediaRepository } from 'src/interfaces/media.interface';
|
2024-04-16 16:44:45 +02:00
|
|
|
import { Mocked, vitest } from 'vitest';
|
2023-03-24 03:40:46 +01:00
|
|
|
|
2024-04-16 16:44:45 +02:00
|
|
|
export const newMediaRepositoryMock = (): Mocked<IMediaRepository> => {
|
2023-03-24 03:40:46 +01:00
|
|
|
return {
|
2024-05-08 15:09:34 +02:00
|
|
|
generateThumbnail: vitest.fn(),
|
2024-04-16 16:44:45 +02:00
|
|
|
generateThumbhash: vitest.fn(),
|
2024-04-19 17:50:13 +02:00
|
|
|
extract: vitest.fn().mockResolvedValue(false),
|
2024-04-16 16:44:45 +02:00
|
|
|
probe: vitest.fn(),
|
|
|
|
transcode: vitest.fn(),
|
2024-04-19 17:50:13 +02:00
|
|
|
getImageDimensions: vitest.fn(),
|
2023-03-24 03:40:46 +01:00
|
|
|
};
|
|
|
|
};
|