提交 85c052a7 authored 作者: Pascal Lamblin's avatar Pascal Lamblin

Add the KnownFailure plugin in call_nose.py

and an option to disable it.
上级 43cbd058
......@@ -7,14 +7,27 @@ This script should behave the same as the `nosetests` command.
The reason for its existence is that on some systems, it may not be obvious to
find where nosetests is installed in order to run it in a different process.
This script is called from `run_tests_in_batch.py`.
"""
This script is called from `run_tests_in_batch.py`.
import sys
It is also used to load the KnownFailure plugin, in order to hide
KnownFailureTests error messages.
"""
import nose
import sys
if __name__ == '__main__':
sys.exit(nose.main())
addplugins = []
# We include KnownFailure plugin by default, unless
# it is disabled by the "--without-knownfailure" arg.
if '--without-knownfailure' not in sys.argv:
try:
from numpy.testing.noseclasses import KnownFailure
addplugins.append(KnownFailure())
except ImportError:
pass
else:
sys.argv.remove('--without-knownfailure')
sys.exit(nose.main(addplugins=addplugins))
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论