[Pytest-commit] commit/tox: 2 new changesets

commits-noreply at bitbucket.org commits-noreply at bitbucket.org
Mon May 19 20:38:12 CEST 2014


2 new commits in tox:

https://bitbucket.org/hpk42/tox/commits/4d9994e4b353/
Changeset:   4d9994e4b353
Branch:      tbekolay/better-setuptools-integration-in-basic-1400524487298
User:        tbekolay
Date:        2014-05-19 20:34:48
Summary:     Better setuptools integration in basic
Affected #:  1 file

diff -r acb4f0db1d405a772c17217b28d87859fc12084e -r 4d9994e4b3539405fc08738554f50ab154eb38a4 doc/example/basic.txt
--- a/doc/example/basic.txt
+++ b/doc/example/basic.txt
@@ -1,4 +1,3 @@
-
 Basic usage
 =============================================
 
@@ -207,6 +206,10 @@
     import sys
 
     class Tox(TestCommand):
+        user_options = [('tox-args=', 'a', "Arguments to pass to tox")]
+        def initialize_options(self):
+            TestCommand.initialize_options(self)
+            self.tox_args = None
         def finalize_options(self):
             TestCommand.finalize_options(self)
             self.test_args = []
@@ -214,7 +217,8 @@
         def run_tests(self):
             #import here, cause outside the eggs aren't loaded
             import tox
-            errno = tox.cmdline(self.test_args)
+            import shlex
+            errno = tox.cmdline(args=shlex.split(self.tox_args))
             sys.exit(errno)
 
     setup(
@@ -227,5 +231,9 @@
 
     python setup.py test
 
-this will install tox and then run tox.
+this will install tox and then run tox. You can pass arguments to ``tox``
+using the ``--tox-args`` or ``-a`` command-line options. For example::
 
+    python setup.py test -a "-epy27"
+
+is equivalent to running ``tox -epy27``.
\ No newline at end of file


https://bitbucket.org/hpk42/tox/commits/8b4012b098d6/
Changeset:   8b4012b098d6
User:        hpk42
Date:        2014-05-19 20:38:10
Summary:     Merged in tbekolay/tox/tbekolay/better-setuptools-integration-in-basic-1400524487298 (pull request #109)

Better setuptools integration in basic
Affected #:  1 file

diff -r acb4f0db1d405a772c17217b28d87859fc12084e -r 8b4012b098d62830708944185a53aaf855915bd1 doc/example/basic.txt
--- a/doc/example/basic.txt
+++ b/doc/example/basic.txt
@@ -1,4 +1,3 @@
-
 Basic usage
 =============================================
 
@@ -207,6 +206,10 @@
     import sys
 
     class Tox(TestCommand):
+        user_options = [('tox-args=', 'a', "Arguments to pass to tox")]
+        def initialize_options(self):
+            TestCommand.initialize_options(self)
+            self.tox_args = None
         def finalize_options(self):
             TestCommand.finalize_options(self)
             self.test_args = []
@@ -214,7 +217,8 @@
         def run_tests(self):
             #import here, cause outside the eggs aren't loaded
             import tox
-            errno = tox.cmdline(self.test_args)
+            import shlex
+            errno = tox.cmdline(args=shlex.split(self.tox_args))
             sys.exit(errno)
 
     setup(
@@ -227,5 +231,9 @@
 
     python setup.py test
 
-this will install tox and then run tox.
+this will install tox and then run tox. You can pass arguments to ``tox``
+using the ``--tox-args`` or ``-a`` command-line options. For example::
 
+    python setup.py test -a "-epy27"
+
+is equivalent to running ``tox -epy27``.
\ No newline at end of file

Repository URL: https://bitbucket.org/hpk42/tox/

--

This is a commit notification from bitbucket.org. You are receiving
this because you have the service enabled, addressing the recipient of
this email.


More information about the pytest-commit mailing list