开发者

How to run all tests in a setup.py script?

I woul开发者_如何学Cd like to write a setup.py script that runs all of my django app's tests and fails the installation if one of the tests don't pass.

How can it be done? What do I need to do?


Assuming you're using setuptools, check out test build package and run a unittest suite from their docs. which I believe lets you run setup.py test and doesn't install your package, but runs the tests in an egg. From here you can run setup.py install. This does seem to be a new command (my version doesn't have it listed).

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜