3 new commits in tox:

https://bitbucket.org/hpk42/tox/commits/228071477cfb/
Changeset:   228071477cfb
User:        ionelmc
Date:        2014-01-11 16:59:44
Summary:     Change tox to use the virtualenv bin instead of invoking it with 
the current interpreter. Virtualenv might have been installed with a completely 
different interpreter (and might not work at all!) or it could have other 
issues caused by invoking the module directly (virtualenv 1.11 known to break). 
Also add a `virtualenvbin` config option in case it need overriding.
Affected #:  3 files

diff -r 4542c26e2a8ad4f1708abe8a2a2024a4825b6e3f -r 
228071477cfbc350fb2e0a437f2ebd5e52f55ee1 tests/test_venv.py
--- a/tests/test_venv.py
+++ b/tests/test_venv.py
@@ -48,11 +48,8 @@
     l = mocksession._pcalls
     assert len(l) >= 1
     args = l[0].args
-    assert "virtualenv" in str(args[1])
+    assert str(args[0]).endswith("virtualenv")
     if sys.platform != "win32":
-        # realpath is needed for stuff like the debian symlinks
-        assert py.path.local(sys.executable).realpath() \
-          == py.path.local(args[0]).realpath()
         #assert Envconfig.toxworkdir in args
         assert venv.getcommandpath("easy_install", cwd=py.path.local())
     interp = venv._getliveconfig().python
@@ -321,7 +318,7 @@
     l = mocksession._pcalls
     assert len(l) == 1
     args = l[0].args
-    assert str(args[1]).endswith('virtualenv.py')
+    assert str(args[0]).endswith('virtualenv')
     l[:] = []
     action = mocksession.newaction(venv, "hello")
     venv._install(["hello"], action=action)

diff -r 4542c26e2a8ad4f1708abe8a2a2024a4825b6e3f -r 
228071477cfbc350fb2e0a437f2ebd5e52f55ee1 tox/_config.py
--- a/tox/_config.py
+++ b/tox/_config.py
@@ -357,6 +357,7 @@
                 ixserver = None
             name = self._replace_forced_dep(name, config)
             vc.deps.append(DepConfig(name, ixserver))
+        vc.virtualenvbin = reader.getdefault(section, "virtualenvbin", 
"virtualenv")
         vc.distribute = reader.getbool(section, "distribute", False)
         vc.sitepackages = self.config.option.sitepackages or \
                           reader.getbool(section, "sitepackages", False)
@@ -734,4 +735,3 @@
     if 'HUDSON_URL' in os.environ:
         return 'jenkins'
     return None
-

diff -r 4542c26e2a8ad4f1708abe8a2a2024a4825b6e3f -r 
228071477cfbc350fb2e0a437f2ebd5e52f55ee1 tox/_venv.py
--- a/tox/_venv.py
+++ b/tox/_venv.py
@@ -178,13 +178,8 @@
         if action is None:
             action = self.session.newaction(self, "create")
 
-        interpreters = self.envconfig.config.interpreters
         config_interpreter = self.getsupportedinterpreter()
-        info = interpreters.get_info(executable=config_interpreter)
-        f, path, _ = py.std.imp.find_module("virtualenv")
-        f.close()
-        venvscript = path.rstrip("co")
-        args = [config_interpreter, str(venvscript)]
+        args = [self.envconfig.virtualenvbin]
         if self.envconfig.distribute:
             args.append("--distribute")
         else:


https://bitbucket.org/hpk42/tox/commits/f54ba7b918e8/
Changeset:   f54ba7b918e8
User:        ionelmc
Date:        2014-01-11 17:09:50
Summary:     Improve assertion to pass on windows.
Affected #:  1 file

diff -r 228071477cfbc350fb2e0a437f2ebd5e52f55ee1 -r 
f54ba7b918e8059fafd341395e32472a8ae3720e tests/test_venv.py
--- a/tests/test_venv.py
+++ b/tests/test_venv.py
@@ -48,7 +48,7 @@
     l = mocksession._pcalls
     assert len(l) >= 1
     args = l[0].args
-    assert str(args[0]).endswith("virtualenv")
+    assert "virtualenv" in str(args[0])
     if sys.platform != "win32":
         #assert Envconfig.toxworkdir in args
         assert venv.getcommandpath("easy_install", cwd=py.path.local())


https://bitbucket.org/hpk42/tox/commits/0b3ce1895d03/
Changeset:   0b3ce1895d03
User:        ionelmc
Date:        2014-01-12 14:18:23
Summary:     Remove virtualenvbin config option.
Affected #:  2 files

diff -r f54ba7b918e8059fafd341395e32472a8ae3720e -r 
0b3ce1895d0387e4fe64afc3dd337e11d6256def tox/_config.py
--- a/tox/_config.py
+++ b/tox/_config.py
@@ -357,7 +357,6 @@
                 ixserver = None
             name = self._replace_forced_dep(name, config)
             vc.deps.append(DepConfig(name, ixserver))
-        vc.virtualenvbin = reader.getdefault(section, "virtualenvbin", 
"virtualenv")
         vc.distribute = reader.getbool(section, "distribute", False)
         vc.sitepackages = self.config.option.sitepackages or \
                           reader.getbool(section, "sitepackages", False)

diff -r f54ba7b918e8059fafd341395e32472a8ae3720e -r 
0b3ce1895d0387e4fe64afc3dd337e11d6256def tox/_venv.py
--- a/tox/_venv.py
+++ b/tox/_venv.py
@@ -179,7 +179,7 @@
             action = self.session.newaction(self, "create")
 
         config_interpreter = self.getsupportedinterpreter()
-        args = [self.envconfig.virtualenvbin]
+        args = ['virtualenv']
         if self.envconfig.distribute:
             args.append("--distribute")
         else:

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.
_______________________________________________
pytest-commit mailing list
pytest-commit@python.org
https://mail.python.org/mailman/listinfo/pytest-commit

Reply via email to