Files
smart-management-auto-test/Joyhub_ui_auto_test/README.md
zhouqi a94eb5dbbe feat: 新增JoyHub UI自动化测试目录
1. 新增 Joyhub_ui_auto_test/ 目录:
   - tests/ - 测试用例目录
   - pages/ - 页面元素定位
   - config/ - 配置文件
   - utils/ - 工具类
   - test_data/ - 测试数据
   - reports/ - 测试报告
   - webapp-testing/ - WebApp测试相关

2. 配置文件:
   - pytest.ini - pytest配置
   - requirements.txt - 依赖列表
   - README.md - 项目说明
2026-05-13 16:01:25 +08:00

51 lines
783 B
Markdown
Raw 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.
# Joyhub_ui_auto_test
Python UI 自动化测试项目,基于 pytest + Playwright。
## 初始化
```bash
python -m venv .venv
.venv\Scripts\activate
pip install -r requirements.txt
playwright install
copy .env.example .env
```
## 运行测试
```bash
pytest
```
## 生成测试报告
项目已配置 pytest-html执行测试后会自动生成 HTML 测试报告:
```bash
pytest
```
报告存放路径:
```text
reports\allure-results\index.html
```
也可以只执行指定用例并生成报告:
```bash
python -m pytest tests/test_open_chrome_browser.py
```
## 目录结构
```text
config/ 配置读取
pages/ Page Object 页面对象
tests/ 测试用例
utils/ 通用工具
test_data/ 测试数据
reports/ 测试报告输出
```