安装生成HTML测试报告命令:pip install pytest 和pip install pytest-html
命名规则:Pytest单元测试中的类名和方法名必须是以test 开头,执行中只能找到test 开头的类和方法,比unittest 更加严谨
安装pytest自带的HTML测试报告命令:pip install pytest-html
运行指定模块指定类指定用例,冒号分割,并生成测试报告:
Original: https://blog.csdn.net/Wshaofu/article/details/124284060
Author: TS_wangshaofu
Title: python pytest+QQ测试用例
原创文章受到原创版权保护。转载请注明出处:https://www.johngo689.com/772354/
转载文章受原作者版权保护。转载请注明原作者出处!