1

我正在使用出色的 Tox 工具来测试我的代码。这是我的tox.ini

[tox]
envlist = py26,py27,py31,py32,py33

[testenv]
deps = ParamUnittest
commands = python -m unittest discover tests
downloadcache = build

[testenv:py26]
deps = https://github.com/rik0/ParamUnittest/tarball/master
       unittest2
       importlib
commands = python -m unittest2.__main__ discover tests

[testenv:py31]
deps = https://github.com/rik0/ParamUnittest/tarball/master
       unittest2py3k
commands = python -m unittest2 discover tests

运行它时,所有测试都在除 3.1 之外的所有版本上执行。毒物显示:

py31 sdist-reinst: /home/miki/exp/radon/.tox/dist/radon-0.1.zip
py31 runtests: commands[0]

----------------------------------------------------------------------
Ran 0 tests in 0.000s

OK

为什么不执行测试?系统布局如下:

tests/
    test_internals.py
    test_complexity.py
    ...
radon/
...
setup.py
tox.ini
4

0 回答 0