- Spring Boot 后端服务 (hss-home-service) - delivery-miniapp 配送小程序 - website 官网 (Nuxt) - docs 架构设计文档 - Docker 容器化部署配置 Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
52 lines
1.9 KiB
TypeScript
52 lines
1.9 KiB
TypeScript
import { test, expect } from '@playwright/test'
|
||
|
||
test.describe('首页模块完整性', () => {
|
||
test.beforeEach(async ({ page }) => { await page.goto('/') })
|
||
|
||
test('Hero 首屏存在', async ({ page }) => {
|
||
await expect(page.locator('h1')).toBeVisible()
|
||
await expect(page.getByText('预约演示').first()).toBeVisible()
|
||
})
|
||
|
||
test('行业痛点模块存在', async ({ page }) => {
|
||
await expect(page.getByText('居家上门服务,为什么这么难管?')).toBeVisible()
|
||
await expect(page.getByText('申请受理难')).toBeVisible()
|
||
await expect(page.getByText('派单调度难')).toBeVisible()
|
||
await expect(page.getByText('过程监管难')).toBeVisible()
|
||
})
|
||
|
||
test('服务闭环流程模块存在', async ({ page }) => {
|
||
await page.getByText('完整服务闭环').scrollIntoViewIfNeeded()
|
||
await page.waitForTimeout(500)
|
||
await expect(page.getByText('完整服务闭环')).toBeVisible()
|
||
})
|
||
|
||
test('核心能力模块存在', async ({ page }) => {
|
||
await expect(page.getByText('八大核心能力')).toBeVisible()
|
||
})
|
||
|
||
test('应用场景模块存在', async ({ page }) => {
|
||
await expect(page.getByText('覆盖五大应用场景')).toBeVisible()
|
||
await expect(page.getByText('政府监管')).toBeVisible()
|
||
await expect(page.getByText('医院延续护理')).toBeVisible()
|
||
})
|
||
|
||
test('数据看板模块存在', async ({ page }) => {
|
||
await expect(page.getByText('实时监管,数据驱动')).toBeVisible()
|
||
})
|
||
|
||
test('安全合规模块存在', async ({ page }) => {
|
||
await expect(page.getByText('医疗级安全合规')).toBeVisible()
|
||
})
|
||
|
||
test('CTA 区块存在', async ({ page }) => {
|
||
await expect(page.getByText('准备好提升居家服务管理效率了吗?')).toBeVisible()
|
||
})
|
||
|
||
test('SVG 图标渲染正常(非 emoji)', async ({ page }) => {
|
||
const svgs = page.locator('svg')
|
||
const count = await svgs.count()
|
||
expect(count).toBeGreaterThan(5)
|
||
})
|
||
})
|