摘要: 1、装 python虚拟环境安装包 pip install python-virtualenv pip install virtualenvwrapper2、 /usr/local 下建一个目录.virtualenvsmkdir /usr/local/.virtualenvs3、设置环境变量 (vi 阅读全文
posted @ 2021-08-10 14:56 wakey 阅读(896) 评论(0) 推荐(0) 编辑
摘要: 转:https://www.cnblogs.com/yoyoketang/p/13537355.html 前言 使用 selenium 做 web 自动化的时候,很多小伙伴希望用例失败的时候能截图,把异常截图展示到allure报告里面。 pytest 有个很好的钩子函数 pytest_runtest 阅读全文
posted @ 2020-09-18 13:33 wakey 阅读(1890) 评论(1) 推荐(0) 编辑
摘要: 转https://www.cnblogs.com/poloyy/category/1690628.html 1|0前言 前面几篇文章主要介绍了allure的特性,这篇文章我们就来讲下allure的标记用法 有时候我们写pytest的时候,会用到 @pytest.mark 但并不会显示在allure报 阅读全文
posted @ 2020-07-18 15:47 wakey 阅读(253) 评论(0) 推荐(0) 编辑
摘要: 转https://www.cnblogs.com/poloyy/category/1690628.html 1|0前言 上一篇文章介绍了两种allure的特性 @allure.description() :添加测试用例描述,一共三种方式哦! @allure.title():指定测试用例标题,默认是函 阅读全文
posted @ 2020-07-18 15:46 wakey 阅读(227) 评论(0) 推荐(0) 编辑
摘要: 转https://www.cnblogs.com/poloyy/category/1690628.html 1|0前言 上一篇文章介绍了两种allure的特性 @allure.step() 装饰器:可以设置测试步骤,让测试用例的执行过程更加详细 allure.attach() 函数:可以设置需要显示 阅读全文
posted @ 2020-07-18 15:45 wakey 阅读(152) 评论(0) 推荐(0) 编辑
摘要: 执行命令: > pytest --alluredir ./report test_a.py > allure serve ./report 阅读全文
posted @ 2020-07-15 14:38 wakey 阅读(413) 评论(0) 推荐(0) 编辑
摘要: @pytest.mark.skip(reason="no way of currently testing this") @pytest.mark.skipif(sys.version_info < (3,6), reason="requires python3.6 or higher") 果条件在 阅读全文
posted @ 2020-07-09 21:34 wakey 阅读(222) 评论(0) 推荐(0) 编辑
摘要: 前言 pytest+allure是最完美的结合了,关于allure的使用,本篇做一个总结。 allure报告可以很多详细的信息描述测试用例,包括epic、feature、story、title、issue、testcase、severity等 环境准备 python 3.6 pytest 4.5.0 阅读全文
posted @ 2020-07-04 16:26 wakey 阅读(744) 评论(0) 推荐(0) 编辑
摘要: pytest结合allure框架可以对用例的等级做详细的划分。 用例等级 allure对用例的等级划分成五个等级 blocker 阻塞缺陷(功能未实现,无法下一步) critical 严重缺陷(功能点缺失) normal 一般缺陷(边界情况,格式错误) minor 次要缺陷(界面错误与ui需求不符) 阅读全文
posted @ 2020-07-04 16:15 wakey 阅读(722) 评论(0) 推荐(0) 编辑
摘要: allure-pytest 环境准备 windows环境相关: python 3.6版本 pytest 4.5.0版本 allure-pytest 2.8.6 最新版 使用pip安装pytest和allure-pytest,加上--index-url地址,下载会快一些 pip install pyt 阅读全文
posted @ 2020-07-04 16:07 wakey 阅读(227) 评论(0) 推荐(0) 编辑