postman+newman+jenkins day12
1.安装node.js
1.1配置环境变量
1.1.2安装Newman
1.1.3配置环境变量
2. Newman 的命令
2.1 常见的参数
-e:
|
使用环境变量
|
-g:
|
使用全局变量
|
-d:
|
使用
csv , text,json 数据驱动 |
-n:
|
循环次数
|
-r :
|
cli,html,json,junit --reporter-html-export
|
2.2 命令
输入命令执行postman批量执行导出文件
newman run C:UsersjackDesktoppostman_collection.json
3.生成测试报告
首先下载html:npm install -g newman-reporter-html
执行命令
newman run C:UsersjackDesktoppostman_collection.json -r html --reporter-html-
export report123.html
结合Jenkins进行持续集成
4.jenkins创建任务
4.2手动获取
4.3成功查看终端日志
4.4 去C盘 查看生成的报告
本图文内容来源于网友网络收集整理提供,作为学习参考使用,版权属于原作者。
THE END
二维码