use TimeService everywhere in the backend
This commit is contained in:
parent
ed750fd990
commit
6cceca90f9
123 changed files with 550 additions and 285 deletions
|
|
@ -10,6 +10,7 @@ import type { Config } from '@/config.js';
|
|||
import Logger, { type Console } from '@/logger.js';
|
||||
import { LoggerService } from '@/core/LoggerService.js';
|
||||
import { bindThis } from '@/decorators.js';
|
||||
import { NativeTimeService, TimeService } from '@/core/TimeService.js';
|
||||
|
||||
/**
|
||||
* Mocked implementation of LoggerService.
|
||||
|
|
@ -35,9 +36,10 @@ export class MockLoggerService extends LoggerService {
|
|||
*/
|
||||
public verbose: boolean;
|
||||
|
||||
constructor(config?: Config) {
|
||||
constructor(config?: Config, timeService?: TimeService) {
|
||||
config ??= { logging: { verbose: false } } as Config;
|
||||
super(config);
|
||||
timeService ??= new NativeTimeService();
|
||||
super(config, timeService);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue