摘要: pytest用例执行时,会发现有很多的参数。例如: 1 # 定义测试集 2 args = ['-v', test_dir, '-s', '-n=4', '-q', '--alluredir', xml_report_path, 3 "--reruns=1", 4 "--reruns-delay=2" 阅读全文
posted @ 2021-08-05 11:05 Mollylin 阅读(99) 评论(0) 推荐(0) 编辑
摘要: 最近在使用pytest做测试,记录一些学习过程中的内容 一、安装方法 pip install pytest 使用规则 测试文件以test_开头(以_test结尾也可) 测试类以Test开头,注意,Test首字母要大写 测试类名称后面直接跟冒号,而不能有() 测试类不能带有 __init__ 方法 测 阅读全文
posted @ 2021-08-05 10:05 Mollylin 阅读(52) 评论(0) 推荐(0) 编辑