File tree Expand file tree Collapse file tree 1 file changed +7
-11
lines changed
Expand file tree Collapse file tree 1 file changed +7
-11
lines changed Original file line number Diff line number Diff line change @@ -23,22 +23,18 @@ const { RosterModule } = require('../../dist/apps/server/modules/roster/roster.m
2323const { FeathersRosterService } = require ( '../../dist/apps/server/modules/roster/service/feathers-roster.service' ) ;
2424const { RabbitMQWrapperModule } = require ( '../../dist/apps/server/infra/rabbitmq/rabbitmq.module' ) ;
2525const { ConfigurationModule } = require ( '../../dist/apps/server/infra/configuration/configuration.module' ) ;
26+ const { DatabaseModule } = require ( '../../dist/apps/server/infra/database/database.module' ) ;
27+ const { DATABASE_CONFIG_TOKEN , DatabaseConfig } = require ( '../../dist/apps/server/infra/database/database.config' ) ;
2628
2729const setupNestServices = async ( app ) => {
2830 const module = await Test . createTestingModule ( {
2931 imports : [
3032 RabbitMQWrapperModule ,
31- MikroOrmModule . forRoot (
32- defineConfig ( {
33- driver : MongoDriver ,
34- clientUrl : DB_URL ,
35- password : DB_PASSWORD ,
36- user : DB_USERNAME ,
37- entities : TEST_ENTITIES ,
38- allowGlobalContext : true ,
39- // debug: true, // use it for locally debugging of querys
40- } )
41- ) ,
33+ DatabaseModule . register ( {
34+ configInjectionToken : DATABASE_CONFIG_TOKEN ,
35+ configConstructor : DatabaseConfig ,
36+ entities : TEST_ENTITIES ,
37+ } ) ,
4238 ConfigurationModule . register ( SERVER_PUBLIC_API_CONFIG_TOKEN , ServerPublicApiConfig ) ,
4339 AccountApiModule ,
4440 TeamApiModule ,
You can’t perform that action at this time.
0 commit comments