chore(formatting): fix formatting for component fixture spec (#10986)

This commit is contained in:
Kara 2016-08-22 10:20:21 -07:00 committed by GitHub
parent 9883e19e2e
commit ece7985b8a
1 changed files with 15 additions and 15 deletions

View File

@ -120,23 +120,23 @@ export function main() {
}));
it('should signal through whenStable when the fixture is stable (autoDetectChanges)',
async(() => {
let componentFixture = TestBed.createComponent(AsyncComp);
componentFixture.autoDetectChanges();
expect(componentFixture.nativeElement).toHaveText('1');
async(() => {
let componentFixture = TestBed.createComponent(AsyncComp);
componentFixture.autoDetectChanges();
expect(componentFixture.nativeElement).toHaveText('1');
let element = componentFixture.debugElement.children[0];
dispatchEvent(element.nativeElement, 'click');
expect(componentFixture.nativeElement).toHaveText('1');
let element = componentFixture.debugElement.children[0];
dispatchEvent(element.nativeElement, 'click');
expect(componentFixture.nativeElement).toHaveText('1');
// Component is updated asynchronously. Wait for the fixture to become stable
// before checking for new value.
expect(componentFixture.isStable()).toBe(false);
componentFixture.whenStable().then((waited) => {
expect(waited).toBe(true);
expect(componentFixture.nativeElement).toHaveText('11');
});
}));
// Component is updated asynchronously. Wait for the fixture to become stable
// before checking for new value.
expect(componentFixture.isStable()).toBe(false);
componentFixture.whenStable().then((waited) => {
expect(waited).toBe(true);
expect(componentFixture.nativeElement).toHaveText('11');
});
}));
it('should signal through isStable when the fixture is stable (no autoDetectChanges)',
async(() => {