Go to file
MengTong Zhu b283cb4097 first commit 2025-05-09 16:34:42 +08:00
.idea first commit 2025-05-09 16:34:42 +08:00
config first commit 2025-05-09 16:34:42 +08:00
execute first commit 2025-05-09 16:34:42 +08:00
logs first commit 2025-05-09 16:34:42 +08:00
resources/images first commit 2025-05-09 16:34:42 +08:00
service first commit 2025-05-09 16:34:42 +08:00
test_case first commit 2025-05-09 16:34:42 +08:00
test_data first commit 2025-05-09 16:34:42 +08:00
utils first commit 2025-05-09 16:34:42 +08:00
.DS_Store first commit 2025-05-09 16:34:42 +08:00
README.md first commit 2025-05-09 16:34:42 +08:00
gtn_qa.iml first commit 2025-05-09 16:34:42 +08:00
requirements.txt first commit 2025-05-09 16:34:42 +08:00
test_example.py first commit 2025-05-09 16:34:42 +08:00

README.md

测试相关项目

模块组成

模块设计

数据生成流程

数据生成流程

环境安装

py3.10以上

pip install -r requirements.txt

目录结构

  • config 配置相关
  • execute 执行入口文件存放
  • resources 其他资源存放
  • service 用例相关方法封装
  • test_case 测试用例,用于存放测试用例
  • test_data 测试数据,用于存放测试数据
    • channel_data 已生成的测试数据
    • data_demo 渠道模版
    • field_config 渠道字段配置
    • field_rules 字段校验规则封装
    • field_sqls 字段获取规则封装
      • sql_config 查询sql配置
  • utils 基础方法封装

数据生成流程

  1. 获取主数据

  2. 拼接主数据,临时储存用于数据拼接和校验等 - holo

  3. 获取dataDemo中的excel模版

  4. 建立字段方法对应关系,字段生成规则 字段 - 方法名称使用枚举做对应关系

  5. 根据主数据,拼接主数据部分,根据字段规则,调用生成其余字段数据

  6. 生成数据数量作为参数传输

  7. 返回生成的数据写入excel