tiny-vue_version0/examples/sites/demos/pc/app/pager/custom-total.spec.ts

14 lines
490 B
TypeScript
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import { test, expect } from '@playwright/test'
test('自定义总条数', async ({ page }) => {
page.on('pageerror', (exception) => expect(exception).toBeNull())
await page.goto('pager#custom-total')
const demo = page.locator('#custom-total')
const pager = demo.locator('.tiny-pager')
const total = pager.locator('.tiny-pager__total')
await expect(total.first()).toHaveText('总条数100万+')
await expect(total.nth(1)).toHaveText('总条数:条数超出百万')
})