Skip to content

Commit

Permalink
test: add time-line UI e2e test (#47)
Browse files Browse the repository at this point in the history
* test: add time-line UI e2e test

* test: 改名
  • Loading branch information
chenxi-20 authored Sep 20, 2024
1 parent 97633a5 commit 83cac4d
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions tests/time-line/xdesign.spec.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
import { expect, test } from '@playwright/test'

test.describe('timeline 组件xdesign规范', () => {
test('节点状态 --UI截图', async ({ page }) => {
page.on('pageerror', (exception) => expect(exception).toBeNull())
await page.goto('time-line#status')
const demo = page.locator('#status .pc-demo')
await expect(demo).toBeInViewport()
await expect(demo).toHaveScreenshot('status.png')
})

test('圆点外观 --UI截图', async ({ page }) => {
page.on('pageerror', (exception) => expect(exception).toBeNull())
await page.goto('time-line#shape')
const demo = page.locator('#shape .pc-demo')
await expect(demo).toBeInViewport()
await expect(demo).toHaveScreenshot('shape.png')
})
})
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 83cac4d

Please sign in to comment.