Tox Testing with a Naked Python Project

You can use tox to run your unit tests across multiple Python versions in a Naked project with the naked test command.  Make sure that tox is installed, place your unit tests in the tests directory, create your tox.ini file in the top level directory (where setup.py is located) and then run:

naked test tox

from any directory in your project.  Your unit tests will be run in all versions of Python that you indicated in the tox.ini configuration file by default.

To run tests in a specific Python version, add one of the tox Python version arguments to the command:

naked test tox py27
naked test tox py33

Note: the Python versions that you select have to be installed locally!

Advertisements