Skip to content

Commit 729451a

Browse files
committed
feat(routing): show alternativ using async and fixture.whenStable
1 parent 4e6e572 commit 729451a

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

src/app/routing/app-routing.module-custom.spec.ts

+7
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,13 @@ describe('The App Routing (with custom cmp)', () => {
4040
location = TestBed.get(Location) as Location;
4141
});
4242

43+
it('should properly redirect to home initially', async(() => {
44+
router.navigate(['']);
45+
routingComponentFixture.whenStable().then(() => {
46+
expect(location.path()).toBe('/home');
47+
});
48+
}));
49+
4350
it(
4451
'should properly navigate back from search to home again',
4552
fakeAsync(() => {

0 commit comments

Comments
 (0)