Skip to content

Commit

Permalink
Merge pull request #3124 from Zac-HD/add-pypy38-to-ci
Browse files Browse the repository at this point in the history
Test on pypy3.8 in CI
  • Loading branch information
Zac-HD authored Oct 20, 2021
2 parents b83c7d4 + 07c0141 commit 595e7e6
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 7 deletions.
1 change: 1 addition & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ jobs:
- check-py37
- check-pypy37
- check-py38
- check-pypy38
- check-py39
- check-py310
- check-quality
Expand Down
2 changes: 1 addition & 1 deletion hypothesis-python/tox.ini
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[tox]
envlist = py{36,py36,37,py37,38,39,310}-{brief,prettyquick,full,custom}
envlist = py{36,py36,37,py37,38,py38,39,310}-{brief,prettyquick,full,custom}
toxworkdir={env:TOX_WORK_DIR:.tox}

[testenv]
Expand Down
22 changes: 16 additions & 6 deletions tooling/src/hypothesistooling/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -360,21 +360,26 @@ def run_tox(task, version):


# See update_python_versions() above
# When adding or removing a version, also update the env lists in tox.ini and
# workflows/main.yml, and the corresponding @python_tests function below.
PY36 = "3.6.15"
PY37 = "3.7.12"
PY38 = PYMAIN = "3.8.12" # Sync PYMAIN minor version with GH Actions main.yml
PY39 = "3.9.7"
PY310 = "3.10.0"
PYPY36 = "pypy3.6-7.3.3"
PYPY37 = "pypy3.7-7.3.5"
PYPY37 = "pypy3.7-7.3.6"
PYPY38 = "pypy3.8-7.3.6"


# ALIASES are the executable names for each Python version
ALIASES = {PYPY36: "pypy3", PYPY37: "pypy3"}

for n in [PY36, PY37, PY38, PY39, PY310]:
major, minor, patch = n.replace("-dev", ".").split(".")
ALIASES[n] = f"python{major}.{minor}"
ALIASES = {}
for name, value in list(globals().items()):
if name.startswith("PYPY"):
ALIASES[value] = "pypy3"
elif name.startswith("PY"):
major, minor, patch = value.replace("-dev", ".").split(".")
ALIASES[value] = f"python{major}.{minor}"


python_tests = task(
Expand Down Expand Up @@ -422,6 +427,11 @@ def check_pypy37():
run_tox("pypy3-full", PYPY37)


@python_tests
def check_pypy38():
run_tox("pypy3-full", PYPY38)


def standard_tox_task(name):
TASKS["check-" + name] = python_tests(lambda: run_tox(name, PYMAIN))

Expand Down

0 comments on commit 595e7e6

Please sign in to comment.