1.Allure.zip包的下载地址:
https://github.com/allure-framework/allure2
在跳转页面选择一个allure.zip包的版本下载
若以上方法无法下载zip报可以在上述的下载地址处选择releases:
在跳转页面选择一个合适版本的allure.zip包
以上操作为下载allure.zip包,下面为安装allure.zip在windows平台
解压allure.zip包
到allure.zip解压后的文件目录的bin目录下运行allure.bat
增加allure到系统环境变量
2.pytest插件安装:pip install pytest-allure-adaptor
3.pytest生成allure测试报告参数:--alluredir=/xxxx/allurereport(此处的目录是allure报告的存放目录,为相对路径)
4.查看allure报告的命令
allure serve allure报告的目录