Skip to content

Commit 7dcd07d

Browse files
committed
Change in behavior with async metadata and prefetch
1 parent 3470155 commit 7dcd07d

File tree

1 file changed

+1
-14
lines changed

1 file changed

+1
-14
lines changed

test/e2e/app-dir/navigation/navigation.test.ts

Lines changed: 1 addition & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -891,23 +891,10 @@ describe('app dir - navigation', () => {
891891
.elementByCss("[href='/metadata-await-promise/nested']")
892892
.click()
893893

894-
if (!isNextDev) {
895-
// next-dev has no prefetch
896-
expect(
897-
await browser
898-
.waitForElementByCss(
899-
'#loading',
900-
// Wait a bit longer than the prefetch duration since the click takes a while to register and the fallback render also takes time.
901-
resolveMetadataDuration + 500
902-
)
903-
.text()
904-
).toEqual('Loading')
905-
expect(await browser.elementByCss('title').text()).toBe('Async Title')
906-
}
907-
908894
await waitFor(resolveMetadataDuration)
909895

910896
expect(await browser.elementById('page-content').text()).toBe('Content')
897+
expect(await browser.elementByCss('title').text()).toBe('Async Title')
911898
})
912899

913900
it('shows a fallback when prefetch completed', async () => {

0 commit comments

Comments
 (0)