mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-22 13:45:18 +00:00
fix: add nuxt load indicator to fixture
This commit is contained in:
parent
df749b9b5b
commit
0646244a30
@ -644,9 +644,15 @@ describe('pages', () => {
|
||||
await page.waitForFunction(path => window.useNuxtApp?.()._route.fullPath === path, '/nested/xyz')
|
||||
await page.goBack()
|
||||
await page.waitForFunction(path => window.useNuxtApp?.()._route.fullPath === path, '/')
|
||||
|
||||
await page.waitForSelector(LOAD_INDICATOR_SELECTOR)
|
||||
let isVisible = await page.isVisible(LOAD_INDICATOR_SELECTOR)
|
||||
expect(isVisible).toBe(true)
|
||||
|
||||
await page.waitForSelector(LOAD_INDICATOR_SELECTOR, { state: 'hidden' })
|
||||
const isVisible = await page.isVisible(LOAD_INDICATOR_SELECTOR)
|
||||
isVisible = await page.isVisible(LOAD_INDICATOR_SELECTOR)
|
||||
expect(isVisible).toBe(false)
|
||||
|
||||
await page.close()
|
||||
})
|
||||
})
|
||||
|
1
test/fixtures/basic/pages/index.vue
vendored
1
test/fixtures/basic/pages/index.vue
vendored
@ -3,6 +3,7 @@
|
||||
<Head>
|
||||
<Title>Basic fixture</Title>
|
||||
</Head>
|
||||
<NuxtLoadingIndicator :throttle="0" />
|
||||
<h1>Hello Nuxt 3!</h1>
|
||||
<div>RuntimeConfig | testConfig: {{ config.public.testConfig }}</div>
|
||||
<div>Composable | foo: {{ foo }}</div>
|
||||
|
Loading…
Reference in New Issue
Block a user