skip装饰器一共有四个
@
unittest.
skip
(reason)
-
Unconditionally skip the decorated test. reason should describe why the test is being skipped.
翻译:无条件跳过用例,reason是说明原因
-
@
unittest.
skipIf
(condition, reason) -
Skip the decorated test if condition is true.
翻译:condition为true的时候跳过
-
@
unittest.
skipUnless
(condition, reason) -
Skip the decorated test unless condition is true.
翻译:condition为False的时候跳过
-
@
unittest.
expectedFailure
-
Mark the test as an expected failure. If the test fails when run, the test is not counted as a failure.
翻译:断言的时候跳过(暂时不知道有啥用,没看懂,貌似断言失败,也变成用例pass了。)