import { TestBed, inject } from '@angular/core/testing'; import { TestsService } from './tests.service'; import { NO_ERRORS_SCHEMA } from '@angular/core'; import { RouterTestingModule } from '@angular/router/testing'; import { HttpClientModule } from '@angular/common/http'; import { MatSnackBarModule } from '@angular/material/snack-bar'; import { FormsModule } from '@angular/forms'; import { AuthenticationService } from '../authentication.service'; describe('TestsService', () => { beforeEach(() => { TestBed.configureTestingModule({ schemas: [NO_ERRORS_SCHEMA], imports: [ RouterTestingModule, HttpClientModule, MatSnackBarModule, FormsModule], providers: [TestsService, AuthenticationService] }); }); it('should be created', inject([TestsService], (service: TestsService) => { expect(service).toBeTruthy(); })); });