commit c6760726dd71de490d27f2096405bb0508534d4d Author: Damian Johnson atagar@torproject.org Date: Sun Feb 1 14:22:38 2015 -0800
Revising tox faq entry
Bit of rewording and adding it to our changelog. --- docs/change_log.rst | 4 ++++ docs/faq.rst | 37 +++++++++++++++++++------------------ 2 files changed, 23 insertions(+), 18 deletions(-)
diff --git a/docs/change_log.rst b/docs/change_log.rst index 21c2105..d48be58 100644 --- a/docs/change_log.rst +++ b/docs/change_log.rst @@ -62,6 +62,10 @@ conversion (:trac:`14075`). * :func:`stem.util.connection.port_usage` always returned None (:trac:`14046`) * Proc connection resolution could fail on especially busy systems (:trac:`14048`)
+ * **Website** + + * Added support and `instructions for tox <faq.html#how-do-i-test-compatibility-with-multiple-python-versions>`_ (:trac:`14091`) + .. _version_1.3:
Version 1.3 diff --git a/docs/faq.rst b/docs/faq.rst index 27aaccf..08781be 100644 --- a/docs/faq.rst +++ b/docs/faq.rst @@ -23,6 +23,7 @@ Frequently Asked Questions
* :ref:`how_do_i_get_started` * :ref:`how_do_i_run_the_tests` + * :ref:`how_do_i_test_compatibility_with_multiple_python_versions` * :ref:`how_do_i_build_the_site` * :ref:`what_is_the_copyright_for_patches`
@@ -504,38 +505,38 @@ of all test runs.
See ``run_tests.py --help`` for more usage information.
-.. _how_do_i_test_compatibility_with_multiple_versions_of_python -How can I test compatibility with multiple versions of python? --------------------------------------------------------------- +.. _how_do_i_test_compatibility_with_multiple_python_versions:
-Stem got support for python 2.6-3.4, testing against all these versions can be -delt with using tox. Fetch the ``python-dev`` package from your package manager -and fetch the respective python versions you want to test against. +How can I test compatibility with multiple python versions? +-----------------------------------------------------------
-Example using a debian based distro: +Stem supports python versions 2.6 and above, including the 3.x series. You can +test all versions of python you presently have installed on your system with +`tox https://testrun.org/tox/`_. If you're using a Debian based system this +can be as simple as...
:: - - ~/stem$ sudo apt-get install python-tox - ~/stem$ sudo apt-get install python2.6 - ~/stem$ sudo apt-get install python3.3 + + ~/stem$ sudo apt-get install python-tox python2.7 python3.3 python-dev python3-dev ~/stem$ tox ... ____ summary _____ - py26: commands succeeded + py27: commands succeeded py33: commands succeeded - congratulations :)
-Tox also allows for customization of arguments for underlying commands and -enviorments. Examples below. +Tox fetches Stem's dependencies for each version of python. One of these +dependencies is pycrypto which requires **python-dev** (or **python3-dev** if +testing with python3). + +Tox also allows you to customize the underlying commands and environments. For +example...
::
- # Run tox with a specefied enviorment + # run the tests with just python 2.6 ~/stem$ tox -e py26
- # Run tox with positonal args for `run_tests.py` - # in a specefied enviorment + # pass arguments to 'run_tests.py' ~/stem$ tox -e py26 -- -u --test response.events
.. _how_do_i_build_the_site:
tor-commits@lists.torproject.org