Remove unnecessary timeouts waiting for command bar (#6199)
This commit is contained in:
@ -38,7 +38,6 @@ test(
|
|||||||
await expect(projectName).toBeVisible()
|
await expect(projectName).toBeVisible()
|
||||||
await projectName.click()
|
await projectName.click()
|
||||||
await scene.settled(cmdBar)
|
await scene.settled(cmdBar)
|
||||||
await page.waitForTimeout(1_000) // wait for panel buttons to be available
|
|
||||||
|
|
||||||
// Expect zero errors in gutter
|
// Expect zero errors in gutter
|
||||||
await expect(page.locator('.cm-lint-marker-error')).not.toBeVisible()
|
await expect(page.locator('.cm-lint-marker-error')).not.toBeVisible()
|
||||||
@ -46,12 +45,10 @@ test(
|
|||||||
// Click the export button
|
// Click the export button
|
||||||
const exportButton = page.getByTestId('export-pane-button')
|
const exportButton = page.getByTestId('export-pane-button')
|
||||||
await expect(exportButton).toBeVisible()
|
await expect(exportButton).toBeVisible()
|
||||||
|
|
||||||
await exportButton.click()
|
await exportButton.click()
|
||||||
await page.waitForTimeout(1_000) // wait for export options to be available
|
|
||||||
|
|
||||||
// Select the first format option
|
// Select the first format option
|
||||||
const gltfOption = page.getByText('glTF')
|
const gltfOption = cmdBar.selectOption({ name: 'glTF' })
|
||||||
const exportFileName = `main.gltf` // source file is named `main.kcl`
|
const exportFileName = `main.gltf` // source file is named `main.kcl`
|
||||||
await expect(gltfOption).toBeVisible()
|
await expect(gltfOption).toBeVisible()
|
||||||
await page.keyboard.press('Enter')
|
await page.keyboard.press('Enter')
|
||||||
@ -59,7 +56,6 @@ test(
|
|||||||
// Click the checkbox
|
// Click the checkbox
|
||||||
const submitButton = page.getByText('Confirm Export')
|
const submitButton = page.getByText('Confirm Export')
|
||||||
await expect(submitButton).toBeVisible()
|
await expect(submitButton).toBeVisible()
|
||||||
await page.waitForTimeout(500)
|
|
||||||
await page.keyboard.press('Enter')
|
await page.keyboard.press('Enter')
|
||||||
|
|
||||||
// Look out for the toast message
|
// Look out for the toast message
|
||||||
@ -113,17 +109,16 @@ test(
|
|||||||
await u.closeFilePanel()
|
await u.closeFilePanel()
|
||||||
await scene.settled(cmdBar)
|
await scene.settled(cmdBar)
|
||||||
|
|
||||||
// expect zero errors in guter
|
// Expect zero errors in gutter
|
||||||
await expect(page.locator('.cm-lint-marker-error')).not.toBeVisible()
|
await expect(page.locator('.cm-lint-marker-error')).not.toBeVisible()
|
||||||
|
|
||||||
// Click the export button
|
// Click the export button
|
||||||
const exportButton = page.getByTestId('export-pane-button')
|
const exportButton = page.getByTestId('export-pane-button')
|
||||||
await expect(exportButton).toBeVisible()
|
await expect(exportButton).toBeVisible()
|
||||||
await exportButton.click()
|
await exportButton.click()
|
||||||
await page.waitForTimeout(1_000) // wait for export options to be available
|
|
||||||
|
|
||||||
// Select the first format option
|
// Select the first format option
|
||||||
const gltfOption = page.getByText('glTF')
|
const gltfOption = cmdBar.selectOption({ name: 'glTF' })
|
||||||
const exportFileName = `other.gltf` // source file is named `other.kcl`
|
const exportFileName = `other.gltf` // source file is named `other.kcl`
|
||||||
await expect(gltfOption).toBeVisible()
|
await expect(gltfOption).toBeVisible()
|
||||||
await page.keyboard.press('Enter')
|
await page.keyboard.press('Enter')
|
||||||
@ -131,7 +126,6 @@ test(
|
|||||||
// Click the checkbox
|
// Click the checkbox
|
||||||
const submitButton = page.getByText('Confirm Export')
|
const submitButton = page.getByText('Confirm Export')
|
||||||
await expect(submitButton).toBeVisible()
|
await expect(submitButton).toBeVisible()
|
||||||
await page.waitForTimeout(500)
|
|
||||||
await page.keyboard.press('Enter')
|
await page.keyboard.press('Enter')
|
||||||
|
|
||||||
// Look out for the toast message
|
// Look out for the toast message
|
||||||
|
|||||||
Reference in New Issue
Block a user