windows搭建jenkins+allure+pytest遇到问题记录

1.

window环境构建选择Execute Windows batch command

 

2.指定python路径

Jenkins首页-->构建执行状态

 

 

 

3 报错:

No module named 'pytest' 

卸载pip uninstall pytest

cmd 命令切换到python的scripts的目录下

重新安装pipip install pytest

 

4,再次构建会遇到其他的no module named ,同样在上个目录下继续安装

pip install allure-pytest

 

主要原因是在IDE运行时,会搜索所有相关的模块,而通过cmd命令或者Jenkins构建时,只会搜索当前目录下的模块

 

 

posted @ 2021-06-11 17:59  后知后觉~T  阅读(220)  评论(0)    收藏  举报