forked from opentiny/tiny-vue
test(steps):[steps] update steps E2E test (#1094)
This commit is contained in:
parent
71e767310d
commit
2e2cf0ab79
|
@ -4,5 +4,6 @@ test('尺寸', async ({ page }) => {
|
||||||
page.on('pageerror', (exception) => expect(exception).toBeNull())
|
page.on('pageerror', (exception) => expect(exception).toBeNull())
|
||||||
await page.goto('steps#size')
|
await page.goto('steps#size')
|
||||||
|
|
||||||
// TODO
|
const miniSteps = page.locator('#size .tiny-steps-block').first()
|
||||||
|
await expect(miniSteps).toHaveClass(/small/)
|
||||||
})
|
})
|
||||||
|
|
|
@ -2,7 +2,13 @@ import { test, expect } from '@playwright/test'
|
||||||
|
|
||||||
test('插槽的使用', async ({ page }) => {
|
test('插槽的使用', async ({ page }) => {
|
||||||
page.on('pageerror', (exception) => expect(exception).toBeNull())
|
page.on('pageerror', (exception) => expect(exception).toBeNull())
|
||||||
await page.goto('steps#slot')
|
await page.goto('steps#slot-item')
|
||||||
|
|
||||||
// TODO
|
const steps = page.locator('#slot-item .tiny-steps')
|
||||||
|
const nodes = steps.locator('li')
|
||||||
|
|
||||||
|
await expect(nodes.first()).toHaveText('Basic Info')
|
||||||
|
await expect(nodes.nth(1)).toHaveText('BOQ Info')
|
||||||
|
await expect(nodes.nth(2)).toHaveText('Involved Parties')
|
||||||
|
await expect(nodes.nth(3)).toHaveText('Billing')
|
||||||
})
|
})
|
||||||
|
|
|
@ -4,5 +4,6 @@ test('文本内容位置', async ({ page }) => {
|
||||||
page.on('pageerror', (exception) => expect(exception).toBeNull())
|
page.on('pageerror', (exception) => expect(exception).toBeNull())
|
||||||
await page.goto('steps#text-position')
|
await page.goto('steps#text-position')
|
||||||
|
|
||||||
// TODO
|
const steps1 = page.locator('#text-position .tiny-steps')
|
||||||
|
await expect(steps1.locator('.tiny-steps-normal')).toHaveClass(/text-right/)
|
||||||
})
|
})
|
||||||
|
|
Loading…
Reference in New Issue