随笔分类 -  Pytest

摘要:安装 pip install mock pip install pytest-mock 实例 第三方接口 payment.py # coding = utf-8 import requests class Payment: # 支付类 def requestOutofSystem(self, car 阅读全文
posted @ 2021-01-10 20:42 冥鸿 阅读(318) 评论(0) 推荐(0)
摘要:第一种:对所有用例使用1、安装:pip install pytest-rerunfailures 2、命令行参数:pytest -- reruns 重试次数 (--reruns-delay 次数之间间隔) pytest --reruns 2 运行失败的用例可以执行2次 pytest --reruns 阅读全文
posted @ 2019-12-31 16:21 冥鸿 阅读(1228) 评论(0) 推荐(0)
摘要:一、parallel 1、安装 pip install pytest-parallel 2、操作命令 –workers (optional) *:多进程运行需要加此参数, *是进程数。默认为1。 –tests-per-worker (optional) *:多线程运行, *是每个worker运行的最 阅读全文
posted @ 2019-12-31 16:18 冥鸿 阅读(3237) 评论(0) 推荐(0)
摘要:一、环境配置 在allure_report目录下(这个目录是生成最后的html报告之前,生成依赖文件的目录 ) 下创建 environment.properties或者environment.xml文件 和 categories.json文件 environment.properties Brows 阅读全文
posted @ 2019-11-18 16:41 冥鸿 阅读(2647) 评论(0) 推荐(0)

Live2D