feat: 根目录文档、脚本、gitignore

This commit is contained in:
2026-10-08 16:15:33 +08:00
commit e98660ce4e
284 changed files with 26838 additions and 0 deletions
+26
View File
@@ -0,0 +1,26 @@
# -*- coding: utf-8 -*-
"""9130 需求文档 tab 验证(CHG-063)"""
import io, sys
from playwright.sync_api import sync_playwright
sys.stdout = io.TextIOWrapper(sys.stdout.buffer, encoding='utf-8')
BASE = 'http://localhost:8088'
with sync_playwright() as p:
browser = p.chromium.launch(channel='chrome', headless=True, args=['--disable-gpu'])
page = browser.new_page(viewport={'width': 1500, 'height': 950})
page.goto(BASE, wait_until='domcontentloaded'); page.wait_for_timeout(2500)
if 'login' in page.url:
page.locator('input[placeholder="用户名"]').fill('admin')
page.locator('input[placeholder="密码"]').fill('123456')
page.locator('text="登录"').first.click(); page.wait_for_timeout(6000)
page.goto(f'{BASE}/#/product-story-info/9130', wait_until='domcontentloaded')
page.wait_for_timeout(6000)
# tab 存在性
tabs = page.locator('.el-tabs__item').all_inner_texts()
print('tabs:', tabs)
page.locator('.el-tabs__item:has-text("需求文档")').first.click(); page.wait_for_timeout(2000)
body = page.inner_text('body')
for t in ['测试用例/测试报告模版', '提交测试报告', '其他测试文档', '代码审查报告', '工作日志', 'AI项目文档更新记录']:
print(t, '✓' if t in body else '✗缺失')
print('左栏交付物在:', '✓' if '交付物' in body else '✗')
page.screenshot(path='tmp/pw_9130_doctab.png', full_page=False)
browser.close()