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