(index: number)
| 20 | |
| 21 | for (const browserAPI of ['navigation', 'history'] as const) { |
| 22 | const expectPageIndex = (index: number) => { |
| 23 | if (browserAPI === 'navigation') { |
| 24 | const navigation = TestBed.inject(PlatformNavigation); |
| 25 | const entries = navigation.entries(); |
| 26 | expect(entries.indexOf(navigation.currentEntry!)).toBe(index); |
| 27 | } else { |
| 28 | expect(TestBed.inject(Location).getState()).toEqual( |
| 29 | jasmine.objectContaining({ɵrouterPageId: index}), |
| 30 | ); |
| 31 | } |
| 32 | }; |
| 33 | |
| 34 | describe(`canceledNavigationResolution: 'computed' with ${browserAPI}-based routing`, () => { |
| 35 | useAutoTick(); |
no test coverage detected
searching dependent graphs…