python中unittest加載測試用例的4種方法

方式一:unittest.main() 方式二:runner.run(discover) (1)test1_register代碼: (2)test2_open代碼: (3)main文件: (4)結果: 方式三:unittest.TextTestRunner().run(suite) (1)test1_register代碼: (2)test2_open代碼: (3)main文件 (4)結果: 方式四
相關文章
相關標籤/搜索