We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
在CI中,如果测试失败,CI依然会通过。问题在于没有把测试结果码传入进程的exit调用。
解决:
在manage.py中调用test时:
@manager.command def test() : import unittest tests = unittest.TestLoader().discover('tests') unittest.TextTestRunner(verbosity=2).run(tests)
TextTestRunner的run之后应该会返回一个结果代码。这个代码应该作为system.exit的参数被传进去。具体可以看这里
The text was updated successfully, but these errors were encountered:
yuyilei
No branches or pull requests
在CI中,如果测试失败,CI依然会通过。问题在于没有把测试结果码传入进程的exit调用。
解决:
在manage.py中调用test时:
TextTestRunner的run之后应该会返回一个结果代码。这个代码应该作为system.exit的参数被传进去。具体可以看这里
The text was updated successfully, but these errors were encountered: