tiny-vue/examples/sites/demos/pc/app/alert/show-icon.spec.ts

10 lines
346 B
TypeScript

import { test, expect } from '@playwright/test'
test('测试 Alert 不显示图标', async ({ page }) => {
page.on('pageerror', (exception) => expect(exception).toBeNull())
await page.goto('alert#show-icon')
const noIconAlert = page.locator('.tiny-alert').nth(1)
await expect(noIconAlert.locator('.tiny-alert__icon')).toHaveCount(1)
})