2024-04-15 18:39:06 -05:00
|
|
|
import { ILoggerRepository } from 'src/interfaces/logger.interface';
|
2024-04-16 09:44:45 -05:00
|
|
|
import { Mocked, vitest } from 'vitest';
|
2024-04-15 18:39:06 -05:00
|
|
|
|
2024-04-16 09:44:45 -05:00
|
|
|
export const newLoggerRepositoryMock = (): Mocked<ILoggerRepository> => {
|
2024-04-15 18:39:06 -05:00
|
|
|
return {
|
2024-04-16 09:44:45 -05:00
|
|
|
setLogLevel: vitest.fn(),
|
|
|
|
setContext: vitest.fn(),
|
2024-05-14 09:28:20 -05:00
|
|
|
setAppName: vitest.fn(),
|
2024-09-27 17:10:39 -05:00
|
|
|
isLevelEnabled: vitest.fn(),
|
2024-04-16 09:44:45 -05:00
|
|
|
verbose: vitest.fn(),
|
|
|
|
debug: vitest.fn(),
|
|
|
|
log: vitest.fn(),
|
|
|
|
warn: vitest.fn(),
|
|
|
|
error: vitest.fn(),
|
|
|
|
fatal: vitest.fn(),
|
2024-04-15 18:39:06 -05:00
|
|
|
};
|
|
|
|
};
|