mirror of
https://github.com/iflytek/skillhub.git
synced 2026-10-08 03:07:51 +00:00
test(e2e): avoid load-event wait in publish flow
This commit is contained in:
parent
7dff8dc697
commit
cc8b56e26c
1 changed files with 3 additions and 6 deletions
|
|
@ -38,13 +38,10 @@ test.describe('Publish Flow UI (Real API)', () => {
|
|||
await expect(page.getByText(path.basename(packagePath))).toBeVisible()
|
||||
const confirmButton = page.getByRole('button', { name: 'Confirm Publish' })
|
||||
await expect(confirmButton).toBeEnabled()
|
||||
await Promise.all([
|
||||
page.waitForURL('**/dashboard/skills'),
|
||||
confirmButton.click(),
|
||||
])
|
||||
await confirmButton.click()
|
||||
|
||||
await expect(page).toHaveURL('/dashboard/skills')
|
||||
await expect(page.getByRole('heading', { name: 'My Skills' })).toBeVisible()
|
||||
await expect(page).toHaveURL(/\/dashboard\/skills$/, { timeout: 90_000 })
|
||||
await expect(page.getByRole('heading', { name: 'My Skills' })).toBeVisible({ timeout: 90_000 })
|
||||
} finally {
|
||||
await builder.cleanup()
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue