From 6cdbb6efa276c11693baff030c6e980681b228fc Mon Sep 17 00:00:00 2001 From: Conor MacBride Date: Thu, 4 Jan 2024 14:49:11 +0000 Subject: [PATCH] Update Python and image versions in tests Bump tox tests by 2 major versions. --- .github/workflows/test_publish.yml | 6 ++-- .github/workflows/test_tox.yml | 54 +++++++++++++++--------------- tox.ini | 16 ++++----- 3 files changed, 38 insertions(+), 38 deletions(-) diff --git a/.github/workflows/test_publish.yml b/.github/workflows/test_publish.yml index b73166f..9bcbf07 100644 --- a/.github/workflows/test_publish.yml +++ b/.github/workflows/test_publish.yml @@ -26,10 +26,10 @@ jobs: test_command: pytest --pyargs test_package targets: | - linux - - cp38-macosx_x86_64 - - cp39-macosx_arm64 + - cp311-macosx_x86_64 + - cp312-macosx_arm64 - cp3?-win_amd64 - - cp39-manylinux_aarch64 + - cp312-manylinux_aarch64 timeout-minutes: 30 release_sdist_only: uses: ./.github/workflows/publish.yml diff --git a/.github/workflows/test_tox.yml b/.github/workflows/test_tox.yml index d816050..85a614c 100644 --- a/.github/workflows/test_tox.yml +++ b/.github/workflows/test_tox.yml @@ -17,17 +17,17 @@ jobs: uses: ./.github/workflows/tox.yml with: envs: | - - linux: py310-inputs-linux - - macos: py39-inputs-macos - - windows: py38-inputs-windows + - linux: py312-inputs-linux + - macos: py311-inputs-macos + - windows: py310-inputs-windows toxargs: '-v' runs-on: windows-2019 - - linux: py310-inputs-conda - - macos: py310-inputs-conda + - linux: py312-inputs-conda + - macos: py312-inputs-conda conda: false posargs: not - - windows: py310-inputs-con_da + - windows: py312-inputs-con_da conda: true pytest: false @@ -37,18 +37,18 @@ jobs: with: conda: 'true' runs-on: | - linux: ubuntu-18.04 - macos: macos-10.15 + linux: ubuntu-20.04 + macos: macos-11 envs: | # conda present in toxenv - - linux: py39-inputs-conda - - linux: py39-inputs-conda + - linux: py311-inputs-conda + - linux: py311-inputs-conda conda: false posargs: not # conda not present in toxenv - - linux: py39-inputs-con_da + - linux: py311-inputs-con_da runs-on: ubuntu-latest - - linux: py39-inputs-con_da + - linux: py311-inputs-con_da conda: auto posargs: not timeout-minutes: 5 @@ -58,18 +58,18 @@ jobs: test_default_python: uses: ./.github/workflows/tox.yml with: - default_python: '3.7' + default_python: '3.9' envs: | - linux: default_python - posargs: '7' + posargs: '9' - linux: default_python - default_python: '3.10' - posargs: '10' - - linux: py311-python_version - python-version: '3.11-dev' + default_python: '3.12' + posargs: '12' + - linux: py313-python_version + python-version: '3.13-dev' posargs: 'CPython' - - linux: pypy39-python_version - python-version: 'pypy-3.9' + - linux: pypy310-python_version + python-version: 'pypy-3.10' posargs: 'PyPy' pytest: false @@ -111,17 +111,17 @@ jobs: - linux: pep8 name: style_check pytest: false - - linux: py310 - - macos: py39 - - windows: py38 + - linux: py312 + - macos: py311 + - windows: py310 test_conda: uses: ./.github/workflows/tox.yml with: envs: | - - linux: py310-conda - - macos: py39-conda - - windows: py38-conda + - linux: py312-conda + - macos: py311-conda + - windows: py310-conda test_setenv: uses: ./.github/workflows/tox.yml @@ -174,7 +174,7 @@ jobs: uses: ./.github/workflows/tox.yml with: envs: | - - linux: py310-linux + - linux: py312-linux pytest-results-summary: true test_prereleases: diff --git a/tox.ini b/tox.ini index dcc1932..6366a77 100644 --- a/tox.ini +++ b/tox.ini @@ -1,10 +1,10 @@ [tox] envlist = pep8 - py3{8,9,10} - py3{8,9,10}-inputs-{linux,macos,windows,conda,con_da} + py3{10,11,12} + py3{10,11,12}-inputs-{linux,macos,windows,conda,con_da} default_python - py{,py}3{9,11}-python_version + py{,py}3{10,13}-python_version libraries cache-{setup,verify} @@ -22,11 +22,11 @@ passenv = MY_VAR commands = # Check the python version is as expected python -c "import sys; assert sys.version_info.major == 3" - py38: python -c "import sys; assert sys.version_info.minor == 8" - py39: python -c "import sys; assert sys.version_info.minor == 9" - pypy39: python -c "import sys; assert sys.version_info.minor == 9" py310: python -c "import sys; assert sys.version_info.minor == 10" py311: python -c "import sys; assert sys.version_info.minor == 11" + pypy311: python -c "import sys; assert sys.version_info.minor == 11" + py312: python -c "import sys; assert sys.version_info.minor == 12" + py313: python -c "import sys; assert sys.version_info.minor == 13" default_python: python -c "import sys; assert sys.version_info.minor == {posargs}" python_version: python -c "import platform; assert platform.python_implementation() == '{posargs}'" # Check the OS is as expected @@ -38,7 +38,7 @@ commands = conda,con_da: python -c "import os, sys; assert {posargs} os.path.exists(os.path.join(sys.prefix, 'conda-meta', 'history'))" # Run a command that should only succeed is the library is installed libraries: {posargs} - # Verify that setenv is working + # Verify that setenv is working setenv-global: python -c "import os; assert os.environ['MY_VAR'] == 'global_value'" setenv-local: python -c "import os; assert os.environ['MY_VAR'] == 'local_value'" # Verify that caching is working @@ -52,7 +52,7 @@ description = verify pep8 deps = flake8 commands = flake8 . --count -[testenv:py3{8,9,10}{,-conda}] +[testenv:py3{10,11,12}{,-conda}] description = run pytest skip_install = false extras = test