From b99d416f541f10d76f959baf4caaba2db174e7df Mon Sep 17 00:00:00 2001 From: James Gerity Date: Fri, 28 Oct 2022 15:06:19 -0400 Subject: [PATCH 1/4] Add explicit list of targets to tox config --- tox.ini | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tox.ini b/tox.ini index 7130b54..6f5738c 100644 --- a/tox.ini +++ b/tox.ini @@ -1,3 +1,6 @@ +[tox] +envlist = py{37,38,39,310,311}, pypy{37,38,39} + [testenv] deps = pytest changedir = tests From 384947af5e54e83658f2bde6a8b8730ed71707f2 Mon Sep 17 00:00:00 2001 From: James Gerity Date: Fri, 28 Oct 2022 15:15:11 -0400 Subject: [PATCH 2/4] Update description of which versions are tested by a bare tox command --- README.md | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 89e12c5..46109fc 100644 --- a/README.md +++ b/README.md @@ -19,8 +19,9 @@ Testing We run the tests using `tox`. This can be installed as usual with `pip install tox`. -Without any options, `tox` will run the tests against the current python version where -`tox` itself was installed: +Without any options, `tox` will run the tests against all of the library's +target Python versions, which will cause an error if one of those versions is +not available. To run tests against a specific python version you can use the `-e` option followed by a tox environment name. E.g. `-e py38` will run tests against Python 3.8. From 0e03333866521adf09528e982c55929e75a8a38e Mon Sep 17 00:00:00 2001 From: James Gerity Date: Fri, 28 Oct 2022 15:26:55 -0400 Subject: [PATCH 3/4] tox: skip missing interpreters --- tox.ini | 1 + 1 file changed, 1 insertion(+) diff --git a/tox.ini b/tox.ini index 6f5738c..ad4ab21 100644 --- a/tox.ini +++ b/tox.ini @@ -1,5 +1,6 @@ [tox] envlist = py{37,38,39,310,311}, pypy{37,38,39} +skip_missing_interpreters = true [testenv] deps = pytest From 4ff603355911563ddfaccc56a7e46bf4737297b3 Mon Sep 17 00:00:00 2001 From: James Gerity Date: Fri, 28 Oct 2022 16:08:15 -0400 Subject: [PATCH 4/4] Correct tox remarks in README --- README.md | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/README.md b/README.md index 46109fc..8492fe1 100644 --- a/README.md +++ b/README.md @@ -20,8 +20,7 @@ Testing We run the tests using `tox`. This can be installed as usual with `pip install tox`. Without any options, `tox` will run the tests against all of the library's -target Python versions, which will cause an error if one of those versions is -not available. +target Python versions. Any missing versions will be skipped. To run tests against a specific python version you can use the `-e` option followed by a tox environment name. E.g. `-e py38` will run tests against Python 3.8.