一、复制非GUI模式下的命令
newman run "e:\\yongli.json" -e "e:\\huanjing.json" -g "e:\\quanju.json" -r cli,html,json,junit --reporter-html-export "e:\\report.html"
二、打开Jenkins新建项目并配置
1、新建项目
2、选择Freestyle project,点击确定。
3、触发器选择Build periodically,*****分别代表分钟、小时、年、月、日。
4、构建选择Execute Windows batch command,并粘贴命令newman run "e:\\yongli.json" -e "e:\\huanjing.json" -g "e:\\quanju.json" -r cli,html,json,junit --reporter-html-export "e:\\report.html",
并且加上Groovy script(该脚本为固定脚本)。
5、选择Publish HTML reports并新增,然后保存即可。