started testing
This commit is contained in:
@ -10,6 +10,7 @@ let httpClientSpy: jasmine.SpyObj<HttpClient>;
|
||||
let localStorageServiceSpy: jasmine.SpyObj<LocalStorageService>;
|
||||
let modalServiceSpy: jasmine.SpyObj<ModalService>;
|
||||
|
||||
// TODO
|
||||
// TODO: test options
|
||||
|
||||
describe('ApiService', () => {
|
||||
|
@ -2,6 +2,8 @@ import { TestBed } from '@angular/core/testing';
|
||||
|
||||
import { AutocompleteService } from './autocomplete.service';
|
||||
|
||||
// TODO
|
||||
|
||||
let autocompleteService: AutocompleteService;
|
||||
|
||||
describe('AutocompleteService', () => {
|
||||
|
@ -1,13 +1,30 @@
|
||||
import { TestBed } from '@angular/core/testing';
|
||||
|
||||
import { DataService } from './data.service';
|
||||
import {ApiService} from './api.service';
|
||||
import {HttpClient} from '@angular/common/http';
|
||||
import {LocalStorageService} from 'angular-2-local-storage';
|
||||
import {ModalService} from '@inst-iot/bosch-angular-ui-components';
|
||||
|
||||
// TODO
|
||||
|
||||
let apiServiceSpy: jasmine.SpyObj<ApiService>;
|
||||
|
||||
|
||||
describe('DataService', () => {
|
||||
let service: DataService;
|
||||
|
||||
beforeEach(() => {
|
||||
TestBed.configureTestingModule({});
|
||||
const apiSpy = jasmine.createSpyObj('ApiService', ['post', 'put']);
|
||||
|
||||
TestBed.configureTestingModule({
|
||||
providers: [
|
||||
{provide: ApiService, useValue: apiSpy}
|
||||
]
|
||||
});
|
||||
service = TestBed.inject(DataService);
|
||||
|
||||
apiServiceSpy = TestBed.inject(ApiService) as jasmine.SpyObj<ApiService>;
|
||||
});
|
||||
|
||||
it('should be created', () => {
|
||||
|
@ -4,6 +4,8 @@ import { LoginService } from './login.service';
|
||||
import {LocalStorageService} from 'angular-2-local-storage';
|
||||
import {ApiService} from './api.service';
|
||||
|
||||
// TODO
|
||||
|
||||
let loginService: LoginService;
|
||||
let apiServiceSpy: jasmine.SpyObj<ApiService>;
|
||||
let localStorageServiceSpy: jasmine.SpyObj<LocalStorageService>;
|
||||
|
@ -1,6 +1,8 @@
|
||||
import { TestBed } from '@angular/core/testing';
|
||||
import { ValidationService } from './validation.service';
|
||||
|
||||
// TODO
|
||||
|
||||
let validationService: ValidationService;
|
||||
|
||||
describe('ValidationService', () => {
|
||||
|
Reference in New Issue
Block a user