Fix frontend tests (#6585)

Fix a few broken tests
This commit is contained in:
Félix Malfait
2024-08-09 08:38:01 +02:00
committed by GitHub
parent ab12d9e8da
commit f2cc385710
17 changed files with 86 additions and 347 deletions

View File

@ -63,9 +63,12 @@ export class MessageQueueCoreModule extends ConfigurableModuleClass {
const driverProvider: Provider = {
provide: QUEUE_DRIVER,
useFactory: async (...args: any[]) => {
const config = await options.useFactory!(...args);
if (options.useFactory) {
const config = await options.useFactory(...args);
return this.createDriver(config);
return this.createDriver(config);
}
throw new Error('useFactory is not defined');
},
inject: options.inject || [],
};