Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
RouterTestingModule.withRoutes = function (routes) {
return { ngModule: RouterTestingModule, providers: [provideRoutes(routes)] };
};
return RouterTestingModule;
static withRoutes(routes, config) {
return {
ngModule: RouterTestingModule,
providers: [
provideRoutes(routes),
{ provide: ROUTER_CONFIGURATION, useValue: config ? config : {} },
]
};
}
}
RouterTestingModule.withRoutes = function (routes, config) {
return {
ngModule: RouterTestingModule_1,
providers: [
provideRoutes(routes),
{ provide: ROUTER_CONFIGURATION, useValue: config ? config : {} },
]
};
};
var RouterTestingModule_1;
RouterTestingModule.withRoutes = function (routes) {
return { ngModule: RouterTestingModule, providers: [provideRoutes(routes)] };
};
RouterTestingModule.decorators = [
RouterTestingModule.withRoutes = function (routes, config) {
return {
ngModule: RouterTestingModule_1,
providers: [
provideRoutes(routes),
{ provide: ROUTER_CONFIGURATION, useValue: config ? config : {} },
]
};
};
var RouterTestingModule_1;
static withRoutes(routes) {
return { ngModule: RouterTestingModule, providers: [provideRoutes(routes)] };
}
}
RouterTestingModule.withRoutes = function (routes) {
return { ngModule: RouterTestingModule, providers: [provideRoutes(routes)] };
};
return RouterTestingModule;
static withRoutes(routes, config) {
return {
ngModule: RouterTestingModule,
providers: [
provideRoutes(routes),
{ provide: ROUTER_CONFIGURATION, useValue: config ? config : {} },
]
};
}
}
RouterTestingModule.withRoutes = function (routes) {
return { ngModule: RouterTestingModule, providers: [provideRoutes(routes)] };
};
RouterTestingModule.decorators = [
beforeEach(() => {
TestBed.configureTestingModule({
declarations: [
TestRouterComponent,
AppComponent
],
imports: [ RouterTestingModule, RouterModule, CoreModule ],
providers: [ provideRoutes(config) ]
});
});