From 2b04e91cfc046b67ee5d2fc3b32357022b6cde37 Mon Sep 17 00:00:00 2001 From: Stefan Scherfke Date: Wed, 25 Jun 2014 09:41:37 +0200 Subject: Add support for PyPy3 (env "pypy3"). --- tests/test_config.py | 8 ++++---- tox/_config.py | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/tests/test_config.py b/tests/test_config.py index ff743c4..bc5a683 100644 --- a/tests/test_config.py +++ b/tests/test_config.py @@ -554,7 +554,7 @@ class TestConfigTestEnv: envconfig = config.envconfigs['python'] assert envconfig.envpython == envconfig.envbindir.join("python") - @pytest.mark.parametrize("bp", ["jython", "pypy"]) + @pytest.mark.parametrize("bp", ["jython", "pypy", "pypy3"]) def test_envbindir_jython(self, tmpdir, newconfig, bp): config = newconfig(""" [testenv] @@ -916,7 +916,7 @@ class TestGlobalOptions: assert str(env.basepython) == sys.executable def test_default_environments(self, tmpdir, newconfig, monkeypatch): - envs = "py26,py27,py31,py32,py33,jython,pypy" + envs = "py26,py27,py31,py32,py33,py34,jython,pypy,pypy3" inisource = """ [tox] envlist = %s @@ -928,8 +928,8 @@ class TestGlobalOptions: env = config.envconfigs[name] if name == "jython": assert env.basepython == "jython" - elif name == "pypy": - assert env.basepython == "pypy" + elif name.startswith("pypy"): + assert env.basepython == name else: assert name.startswith("py") bp = "python%s.%s" %(name[2], name[3]) diff --git a/tox/_config.py b/tox/_config.py index 4f89d00..1495bd8 100644 --- a/tox/_config.py +++ b/tox/_config.py @@ -15,7 +15,7 @@ import tox iswin32 = sys.platform == "win32" -defaultenvs = {'jython': 'jython', 'pypy': 'pypy'} +defaultenvs = {'jython': 'jython', 'pypy': 'pypy', 'pypy3': 'pypy3'} for _name in "py,py24,py25,py26,py27,py30,py31,py32,py33,py34".split(","): if _name == "py": basepython = sys.executable -- cgit v1.2.1