diff --git a/frontend/app/model/network/autehentication.service.spec.ts b/frontend/app/model/network/autehentication.service.spec.ts index 797f54c3..a533950e 100644 --- a/frontend/app/model/network/autehentication.service.spec.ts +++ b/frontend/app/model/network/autehentication.service.spec.ts @@ -5,6 +5,7 @@ import {LoginCredential} from '../../../../common/entities/LoginCredential'; import {AuthenticationService} from './authentication.service'; import {NetworkService} from './network.service'; import {ErrorDTO} from '../../../../common/entities/Error'; +import {VersionService} from '../version.service'; class MockUserService { public login(credential: LoginCredential): Promise { @@ -25,6 +26,7 @@ describe('AuthenticationService', () => { beforeEach(() => { TestBed.configureTestingModule({ providers: [ + VersionService, {provide: NetworkService, useClass: MockNetworkService}, {provide: UserService, useClass: MockUserService}, AuthenticationService, diff --git a/frontend/app/model/network/network.service.spec.ts b/frontend/app/model/network/network.service.spec.ts index b4746721..0b713297 100644 --- a/frontend/app/model/network/network.service.spec.ts +++ b/frontend/app/model/network/network.service.spec.ts @@ -3,6 +3,7 @@ import {HttpClientTestingModule, HttpTestingController} from '@angular/common/ht import {NetworkService} from './network.service'; import {Message} from '../../../../common/entities/Message'; import {SlimLoadingBarService} from 'ng2-slim-loading-bar'; +import {VersionService} from '../version.service'; describe('NetworkService Success tests', () => { @@ -18,6 +19,7 @@ describe('NetworkService Success tests', () => { TestBed.configureTestingModule({ imports: [HttpClientTestingModule], providers: [ + VersionService, SlimLoadingBarService, NetworkService ] @@ -130,6 +132,7 @@ describe('NetworkService Fail tests', () => { TestBed.configureTestingModule({ imports: [HttpClientTestingModule], providers: [ + VersionService, SlimLoadingBarService, NetworkService ] diff --git a/frontend/app/model/network/user.service.spec.ts b/frontend/app/model/network/user.service.spec.ts index fd324bf3..54ab5690 100644 --- a/frontend/app/model/network/user.service.spec.ts +++ b/frontend/app/model/network/user.service.spec.ts @@ -5,6 +5,7 @@ import {UserService} from './user.service'; import {LoginCredential} from '../../../../common/entities/LoginCredential'; import {SlimLoadingBarService} from 'ng2-slim-loading-bar'; import {ShareService} from '../../gallery/share.service'; +import {VersionService} from '../version.service'; class MockShareService { wait() { @@ -23,6 +24,7 @@ describe('UserService', () => { TestBed.configureTestingModule({ imports: [HttpClientTestingModule], providers: [ + VersionService, UserService, SlimLoadingBarService, NetworkService,