From 943f7a55f76473653d51bd488ecd12beb266c1f3 Mon Sep 17 00:00:00 2001 From: "Patrick J. Roddy" Date: Tue, 1 Oct 2024 10:01:53 +0100 Subject: [PATCH 1/2] First attempt at tomlifying `tox` --- pyproject.toml | 49 +++++++++++++++++++++++++++---------------------- 1 file changed, 27 insertions(+), 22 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index aeab59f..0e2a26e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -140,25 +140,30 @@ overrides."tool.coverage.paths.source".inline_arrays = false overrides."tool.ruff.lint.isort.section-order".inline_arrays = false [tool.tox] -legacy_tox_ini = """ - [gh-actions] - python = - 3.10: py310 - 3.11: py311 - 3.12: py312 - - [gh-actions:env] - OS = - ubuntu-latest: linux - macos-latest: macos - windows-latest: windows - - [testenv] - commands = - pytest --cov --cov-report=lcov - deps = - pytest-cov - - [tox] - env_list = py{310,311,312}-{linux,macos,windows} -""" +env_list = [ + "py310-linux", + "py310-macos", + "py310-windows", + "py311-linux", + "py311-macos", + "py311-windows", + "py312-linux", + "py312-macos", + "py312-windows", +] +gh-actions.python = [ + "3.10: py310", + "3.11: py311", + "3.12: py312", +] +gh-actions.env.OS = [ + "macos-latest: macos", + "ubuntu-latest: linux", + "windows-latest: windows", +] +testenv.commands = [ + "pytest --cov --cov-report=lcov", +] +testenv.deps = [ + "pytest-cov", +] From 7e35526ba1ff476ca96ba9cf53800c5a992d172f Mon Sep 17 00:00:00 2001 From: "Patrick J. Roddy" Date: Tue, 1 Oct 2024 10:15:41 +0100 Subject: [PATCH 2/2] Put `tox-gh-actions` back into INI support --- pyproject.toml | 30 ++++++++++++++++-------------- 1 file changed, 16 insertions(+), 14 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 0e2a26e..b0b351b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -151,19 +151,21 @@ env_list = [ "py312-macos", "py312-windows", ] -gh-actions.python = [ - "3.10: py310", - "3.11: py311", - "3.12: py312", -] -gh-actions.env.OS = [ - "macos-latest: macos", - "ubuntu-latest: linux", - "windows-latest: windows", -] -testenv.commands = [ +legacy_tox_ini = """ + [gh-actions] + python = + 3.10: py310 + 3.11: py311 + 3.12: py312 + + [gh-actions:env] + OS = + ubuntu-latest: linux + macos-latest: macos + windows-latest: windows +""" +env.testenv = {commands = [ "pytest --cov --cov-report=lcov", -] -testenv.deps = [ +], deps = [ "pytest-cov", -] +]}