only click a size button if measurements are required
This commit is contained in:
parent
b2e1a36076
commit
1a4654d686
2 changed files with 9 additions and 5 deletions
|
@ -1,14 +1,18 @@
|
|||
import { test, expect } from '@playwright/test'
|
||||
|
||||
test('test', async ({ page }) => {
|
||||
test('Compiles and drafts', async ({ page }) => {
|
||||
await page.goto('http://localhost:8000/')
|
||||
await page.getByRole('link', { name: '👉 To your design 👈' }).click()
|
||||
await page
|
||||
|
||||
const sizeButton = page
|
||||
.getByRole('list')
|
||||
.filter({ hasText: 'Size 28Size 30Size 32Size 34Size 36Size 38Size 40Size 42Size 44Size 46' })
|
||||
.getByRole('button', { name: 'Size 36' })
|
||||
.click()
|
||||
await page.getByTitle('draftDesign').click()
|
||||
|
||||
if (await sizeButton.isVisible()) {
|
||||
await sizeButton.click()
|
||||
await page.getByTitle('draftDesign').click()
|
||||
}
|
||||
|
||||
await expect(page.getByText('Something went wrong')).toHaveCount(0)
|
||||
await expect(page.getByText('Unhandled Runtime Error')).toHaveCount(0)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue