https://github.com/chmouel/tox.el.git
git clone 'git://github.com/chmouel/tox.el.git'
tox.el is an Emacs mode interface to tox the virtualenv-based automation of test activities, see https://pypi.python.org/pypi/tox
In python mode if you are on a test and do M-x tox-current-test
the
current test will be launched with tox in a compilation buffer. Use
M-x tox-current-class
to test the current class.
With a prefix to the test function tox.el
will ask you for a tox
environement (which is by default what specified in tox-default-env
)
parsing your tox.ini.
Since tox
is pretty flexible with the underlying test runner, the calling argument can get different depending of which test runner you are using.
By default tox.el
will call the test like th way python-nose is expecting to have :
tox directory.tests.test_file:Class.object
sometime you may use testr which expect only dot and not collon, you can then setup the variable tox-use-all-dot-style
to tru to get this behavior :
tox directory.tests.test_file.Class.object
You may want to set that per-project within your project's .dirs-locals.el
file.
Using a .dirs-locals.el at the top directory of your project makes it easier to run your tests and not getting aksed by a tox target everytime. Here is an example setting the py27 as the default environment have set the tox-use-all-dot-style
variable.
((nil . ((tox-default-env . "py27")
(tox-use-all-dot-style . t))))
You can install tox.el
from
MELPA with package.el
(M-x package-install tox
).
And you can also install it with el-get.
git checkout -b my-new-feature
git commit -am 'Add some feature'
git push origin my-new-feature
Apache