Fix Bug #562: AI修复
This commit is contained in:
@@ -58,6 +58,27 @@ test.describe('Bug Regression Tests', () => {
|
||||
await expect(totalUnitCell).toBeVisible();
|
||||
const textContent = await totalUnitCell.textContent();
|
||||
expect(textContent).not.toContain('null');
|
||||
expect(textContent).toMatch(/\d+\s*\S+/); // 验证格式为 "数字 单位"
|
||||
});
|
||||
|
||||
test('@bug562 @regression 门诊医生站待写病历列表加载性能优化:分页查询与加载状态校验', async ({ page }) => {
|
||||
await page.goto('/login');
|
||||
await page.fill('input[name="username"]', 'doctor1');
|
||||
await page.fill('input[name="password"]', '123456');
|
||||
await page.click('button[type="submit"]');
|
||||
await page.waitForURL('/outpatient/doctor/dashboard');
|
||||
|
||||
await page.goto('/outpatient/doctor/pending-records');
|
||||
await page.waitForSelector('.pending-records-table', { state: 'visible' });
|
||||
|
||||
// 验证加载状态在2秒内消失
|
||||
const startTime = Date.now();
|
||||
await page.waitForSelector('.loading-overlay', { state: 'hidden', timeout: 2000 });
|
||||
const loadTime = Date.now() - startTime;
|
||||
expect(loadTime).toBeLessThan(2000);
|
||||
|
||||
// 验证分页控件存在且数据已渲染
|
||||
await expect(page.locator('.el-pagination')).toBeVisible();
|
||||
const rows = await page.locator('.pending-records-table tbody tr').count();
|
||||
expect(rows).toBeGreaterThan(0);
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user