Skip to content

Commit

Permalink
fix: detectChanges when component is stable
Browse files Browse the repository at this point in the history
  • Loading branch information
LeJeanbono committed Jul 31, 2020
1 parent 61a63ec commit fb12678
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions lib/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ export const mount = (component: any, inputs?: object) => {
const fixture = TestBed.createComponent(component);
let componentInstance = fixture.componentInstance;
componentInstance = Object.assign(componentInstance, inputs);
fixture.whenStable().then(() => fixture.detectChanges());
fixture.detectChanges();
return fixture;
};
Expand Down

0 comments on commit fb12678

Please sign in to comment.