From 2f9492b4af0f91ff56b1b3d1c489ad33d66013b2 Mon Sep 17 00:00:00 2001 From: Jonathan Kim Date: Wed, 14 Jul 2021 16:57:44 +0100 Subject: [PATCH] Update tox file --- .github/workflows/tests.yml | 2 ++ tox.ini | 25 +++++++++++++++---------- 2 files changed, 17 insertions(+), 10 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index efb0ae3c..4af6af2e 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -22,3 +22,5 @@ jobs: pip install tox tox-gh-actions - name: Test with tox run: tox + env: + TOXENV: ${{ matrix.toxenv }} diff --git a/tox.ini b/tox.ini index a519cb1e..7178b186 100644 --- a/tox.ini +++ b/tox.ini @@ -1,20 +1,27 @@ [tox] -envlist = flake8,py27,py34,py35,py36,py37,pre-commit,pypy,mypy -skipsdist = true +envlist = py{27,36,37,38,39},flake8,pre-commit,mypy + +[gh-actions] +python = + 2.7: py27 + 3.6: py36 + 3.7: py37 + 3.8: py38 + 3.9: py39 [testenv] +passenv = * +usedevelop = True deps = - .[test] - py{35,36,37}: pytest-asyncio + -e.[test] + py{36,37,38,39}: pytest-asyncio setenv = PYTHONPATH = .:{envdir} commands = - py{27,py}: py.test --cov=graphene graphene examples {posargs} - py{35}: py.test --cov=graphene graphene examples tests_asyncio {posargs} - py{36,37}: py.test --cov=graphene graphene examples tests_asyncio tests_py36 {posargs} + py{27}: py.test --cov=graphene graphene examples {posargs} + py{36,37,38,39}: py.test --cov=graphene graphene examples tests_asyncio tests_py36 {posargs} [testenv:pre-commit] -basepython=python3.7 deps = pre-commit>0.12.0 setenv = @@ -34,5 +41,3 @@ deps = flake8 commands = pip install -e . flake8 graphene - -[pytest]