-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathpytest.ini
More file actions
33 lines (28 loc) · 916 Bytes
/
Copy pathpytest.ini
File metadata and controls
33 lines (28 loc) · 916 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
[pytest]
# pytest 配置文件
testpaths = UI_Automation/Tests API_Automation/cases
python_files = test_*.py
python_classes = Test*
python_functions = test_*
# 标记
markers =
smoke: 冒烟测试 (P0)
regression: 回归测试 (P1)
api: 接口测试
ui: UI测试
slow: 耗时较长的测试
# 日志
log_cli = true
log_cli_level = INFO
log_format = %(asctime)s [%(levelname)s] %(name)s: %(message)s
log_date_format = %Y-%m-%d %H:%M:%s
# Allure
allure_severities = blocker critical normal minor trivial
allure_epics = 用户模块 商品模块 购物车模块 订单模块
allure_features = 登录 注册 首页 分类 详情 购物车 下单 支付
# 重试和并发
# API 测试并发执行,UI 测试串行(设备独占)
addopts = -v --tb=short --strict-markers --reruns 2 --reruns-delay 1 -n auto
# 超时(需要 pip install pytest-timeout)
timeout = 300
timeout_method = thread