From a5277b4867fd93ab4963c67a97dd33921616bf56 Mon Sep 17 00:00:00 2001 From: Roman Mogylatov Date: Sun, 30 Oct 2022 21:26:46 -0400 Subject: [PATCH 1/3] Update tests --- .../unit/providers/coroutines/test_abstract_coroutine_py35.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tests/unit/providers/coroutines/test_abstract_coroutine_py35.py b/tests/unit/providers/coroutines/test_abstract_coroutine_py35.py index 4f098442..85e1c218 100644 --- a/tests/unit/providers/coroutines/test_abstract_coroutine_py35.py +++ b/tests/unit/providers/coroutines/test_abstract_coroutine_py35.py @@ -1,6 +1,7 @@ """AbstractCoroutine provider tests.""" import asyncio +import sys from dependency_injector import providers, errors from pytest import mark, raises @@ -14,6 +15,7 @@ def test_inheritance(): @mark.asyncio @mark.filterwarnings("ignore") +@mark.skipif(sys.version_info >= (3, 11), reason="Cannot be executed on Python 3.11 or newer") async def test_call_overridden_by_coroutine(): @asyncio.coroutine def abstract_example(): @@ -28,6 +30,7 @@ async def test_call_overridden_by_coroutine(): @mark.asyncio @mark.filterwarnings("ignore") +@mark.skipif(sys.version_info >= (3, 11), reason="Cannot be executed on Python 3.11 or newer") async def test_call_overridden_by_delegated_coroutine(): @asyncio.coroutine def abstract_example(): From 2f64d2da60c0c4fa5d1ef42ed2e8546c581e3acd Mon Sep 17 00:00:00 2001 From: Roman Mogylatov Date: Sun, 30 Oct 2022 21:30:24 -0400 Subject: [PATCH 2/3] Enable tests on 3.11 --- .github/workflows/tests-and-linters.yml | 6 +++--- setup.py | 1 + tox.ini | 2 +- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/.github/workflows/tests-and-linters.yml b/.github/workflows/tests-and-linters.yml index 213fb543..600f550a 100644 --- a/.github/workflows/tests-and-linters.yml +++ b/.github/workflows/tests-and-linters.yml @@ -9,7 +9,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - python-version: [2.7, 3.5, 3.6, 3.7, 3.8, 3.9, "3.10", pypy2, pypy3] + python-version: [2.7, 3.5, 3.6, 3.7, 3.8, 3.9, "3.10", 3.11, pypy2, pypy3] steps: - uses: actions/checkout@v2 - uses: actions/setup-python@v2 @@ -31,7 +31,7 @@ jobs: - uses: actions/checkout@v2 - uses: actions/setup-python@v2 with: - python-version: "3.10" + python-version: "3.11" - run: pip install tox cython - run: make cythonize - run: tox @@ -48,7 +48,7 @@ jobs: - uses: actions/checkout@v2 - uses: actions/setup-python@v2 with: - python-version: "3.10" + python-version: "3.11" - run: pip install tox - run: tox env: diff --git a/setup.py b/setup.py index 82c8e8ff..890268e5 100644 --- a/setup.py +++ b/setup.py @@ -106,6 +106,7 @@ setup(name="dependency-injector", "Programming Language :: Python :: 3.8", "Programming Language :: Python :: 3.9", "Programming Language :: Python :: 3.10", + "Programming Language :: Python :: 3.11", "Programming Language :: Python :: Implementation :: CPython", "Programming Language :: Python :: Implementation :: PyPy", "Framework :: AsyncIO", diff --git a/tox.ini b/tox.ini index 726e77bc..52720d35 100644 --- a/tox.ini +++ b/tox.ini @@ -1,6 +1,6 @@ [tox] envlist= - coveralls, pylint, flake8, pydocstyle, 2.7, 3.5, 3.6, 3.7, 3.8, 3.9, 3.10, pypy2, pypy3 + coveralls, pylint, flake8, pydocstyle, 2.7, 3.5, 3.6, 3.7, 3.8, 3.9, 3.10, 3.11, pypy2, pypy3 [testenv] deps= From 04df609631c39b3e2abfeaabe48b7071cd9d3dbd Mon Sep 17 00:00:00 2001 From: Roman Mogylatov Date: Sun, 30 Oct 2022 21:33:10 -0400 Subject: [PATCH 3/3] Fix coverage config in tox.ini --- tox.ini | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tox.ini b/tox.ini index 52720d35..e88542de 100644 --- a/tox.ini +++ b/tox.ini @@ -24,7 +24,7 @@ python_files = test_*_py3*.py [testenv:coveralls] passenv = GITHUB_* COVERALLS_* -basepython=python3.10 +basepython=python3.11 usedevelop=True deps= {[testenv]deps}