摘要: 1,放到fixture中 2,使用第三方插件 pytest-datadir and pytest-datafiles 3,放到文件中 阅读全文
posted @ 2020-08-17 11:43 myy2 阅读(207) 评论(0) 推荐(0) 编辑
摘要: 1,fixture是依赖注入的一种形式 2,fixture的发现先后规则为:测试类,测试模块,coftest,内置,第三方 多个fixture的运行先后顺序:作用范围越高,越先运行,autouse的优先级高于非autouse的,有依赖的fixture先运行依赖的fixtue,按照注入的先后顺序执行 阅读全文
posted @ 2020-08-17 11:38 myy2 阅读(375) 评论(0) 推荐(0) 编辑