diff --git a/projects/cobbler-frontend/src/app/services/auth-guard.service.spec.ts b/projects/cobbler-frontend/src/app/services/auth-guard.service.spec.ts index 45e78d77..92255345 100644 --- a/projects/cobbler-frontend/src/app/services/auth-guard.service.spec.ts +++ b/projects/cobbler-frontend/src/app/services/auth-guard.service.spec.ts @@ -1,5 +1,5 @@ import { TestBed } from '@angular/core/testing'; -import { RouterTestingModule } from '@angular/router/testing'; +import { provideRouter } from "@angular/router"; import { AuthGuardService } from './auth-guard.service'; import { UserService } from './user.service'; @@ -9,8 +9,10 @@ describe('AuthGuardService', () => { beforeEach(() => { TestBed.configureTestingModule({ - imports: [RouterTestingModule], - providers: [UserService], + providers: [ + provideRouter([]), + UserService, + ], }); service = TestBed.inject(AuthGuardService); });