Fix test
This commit is contained in:
parent
dbe0107281
commit
1bbba774b3
1 changed files with 21 additions and 24 deletions
|
@ -3,6 +3,8 @@ import {async, ComponentFixture, TestBed} from '@angular/core/testing';
|
|||
import {FormsModule} from '@angular/forms';
|
||||
import {InputComponentManagerService} from './inputcomponentmanager.service';
|
||||
import {Step} from './step';
|
||||
import {ConverterRegistryService} from './converterregistry.service';
|
||||
import {Converter} from './converter/converter';
|
||||
|
||||
describe('AppComponent', () => {
|
||||
let sut: AppComponent;
|
||||
|
@ -15,14 +17,25 @@ describe('AppComponent', () => {
|
|||
}
|
||||
};
|
||||
|
||||
const converterRegistryServiceStub = {
|
||||
getAllConverters: (): Converter[] => {
|
||||
return [];
|
||||
},
|
||||
|
||||
getConverter: (id: string): Converter => {
|
||||
return undefined;
|
||||
}
|
||||
};
|
||||
|
||||
beforeEach(async(() => {
|
||||
/*return */
|
||||
TestBed.configureTestingModule({
|
||||
declarations: [AppComponent],
|
||||
imports: [FormsModule],
|
||||
providers: [{
|
||||
provide: InputComponentManagerService, useValue: inputComponentManagerServiceStub
|
||||
}]
|
||||
providers: [
|
||||
{provide: InputComponentManagerService, useValue: inputComponentManagerServiceStub},
|
||||
{provide: ConverterRegistryService, useValue: converterRegistryServiceStub}
|
||||
]
|
||||
})
|
||||
.compileComponents();
|
||||
}));
|
||||
|
@ -31,26 +44,10 @@ describe('AppComponent', () => {
|
|||
fixture = TestBed.createComponent(AppComponent);
|
||||
sut = fixture.componentInstance;
|
||||
});
|
||||
// beforeEach(async(() => {
|
||||
// TestBed.configureTestingModule({
|
||||
// imports: [
|
||||
// RouterTestingModule
|
||||
// ],
|
||||
// declarations: [
|
||||
// AppComponent
|
||||
// ],
|
||||
// }).compileComponents();
|
||||
// }));
|
||||
|
||||
it('should be true that true is true', () => {
|
||||
expect(true).toBe(true);
|
||||
});
|
||||
|
||||
// it('should create the app', async(() => {
|
||||
// const fixture = TestBed.createComponent(AppComponent);
|
||||
// const app = fixture.debugElement.componentInstance;
|
||||
// expect(app).toBeTruthy();
|
||||
// }));
|
||||
|
||||
|
||||
it('should create the app', async(() => {
|
||||
// const fixture = TestBed.createComponent(AppComponent);
|
||||
const app = fixture.debugElement.componentInstance;
|
||||
expect(app).toBeTruthy();
|
||||
}));
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue