dev-python/pytest-asyncio: treeclean

Signed-off-by: Andreas Billmeier <b@edevau.net>
This commit is contained in:
2024-04-12 21:32:35 +02:00
parent 9eb25f3a5d
commit f14ecea7dd
7 changed files with 2 additions and 232 deletions

View File

@@ -1,8 +0,0 @@
AUX pytest-asyncio-0.23.4-pytest-8.patch 1736 BLAKE2B 8f603b2a2c468f1f85c92842f0b47ca8ade9e6e45bfb9b417da61410604faf209e468e9a716a56bf714bab9d5b14aef822db300a27168f65c35dda1844d43a71 SHA512 badde4aaf63f995ff38fc2ef6804fd0b5cfdc5ce7fbd5e2e3f28048c1e64dacf1d1929cac0d15ec801e74ad49e634540209c9baa8c09f2a5e19e4016ff8142f0
DIST pytest-asyncio-0.14.0.gh.tar.gz 14796 BLAKE2B 0a110dabde491293dc10452239971809ec6a4006a2036e848aac067df1af328d0d1d5c7afae8cfc1ecf5c919c0922050e2db182065500ec614a8094d3799c0cd SHA512 d1fadff152a0c94f80a8272a0dd293bd9d9300ad9e79c69556b5901c1a8ce00545f7715e503a383e3f4f35c8090d8f9ec33d16739b85378b59b1786a50441fca
DIST pytest-asyncio-0.21.0.gh.tar.gz 28675 BLAKE2B d3b4121a6849c9c508dfe59b0ee0adb4d20a3365ebcd6df51db50c576e716634c0d3a8ae5932ac2f36085795b10cd47d2ff61f90a22645d199aa2debebc22b23 SHA512 d678d8957e091753684841fff668284d591587d3190db514afd3713b9fe94826b27d1b455b7ac4447a67587203d5caabf8611e199cbb9792e5171072fe55d823
DIST pytest-asyncio-0.23.4.tar.gz 45162 BLAKE2B 69092bff908beb2b707d281142145edf0508bcb09aa59e4a91d18b3cdb24e5533436a9668e2d243425b4914f2913e6186fa6d8b6c1d187b6bf25191986d27981 SHA512 831c572ae981b8575f97dd4d0d40d960d49cbeeb6b186e1c094eb45b1f48210824780ca14cbf44d1da558b1a17ca1fefc0eda26137461172bbd12f8b25ab8ebb
EBUILD pytest-asyncio-0.14.0.ebuild 1184 BLAKE2B 3757755033a717ca128a9e9a1add92172f03ec7b1558374305708760a81d39e8405d25435d9d5ec80c1c46d08e217b8633fb5fe788f116784ebc8c1e6c12d41d SHA512 a0073d3e834cdd3cd802d6ec91e302782ddc58d88ad486d656739b8069fa0a368f517c83df416440509fe9c63eedee821b607e19bee03b796077405c59c1073f
EBUILD pytest-asyncio-0.21.0.ebuild 1184 BLAKE2B cb6a9d93e23ba40d705b48b2eae35426441196855ecd7b1e413fed462c29120dadb2479fa12b5222d4d8c3900eda951989655f043c4953f232a5823c8b244fb4 SHA512 c18ef45583eae321bfce97427b1208292ff5b398383014e3e4901e960322a76449c595dfaca8858e3030e6fc94f913a9c57b3e9c3249d7aa8fb6ab5302a8524d
EBUILD pytest-asyncio-0.23.4-r1.ebuild 1718 BLAKE2B cc45a5663ffdc9ca3d49e1e4517e633730810e2818ba78f026312df663222f296aebe2139fac5cf14666a51c14e91b28340a9a8de6d8a16eb1f94b72a5e53b19 SHA512 22a19f0259fd253a1dced23f1f49e6a38f54d3c433ee2e8618b4d542aab7923610b638803c8fdc792f79399607c8b3d7274ad32f7427ac35383031e28ec087a3
MISC metadata.xml 557 BLAKE2B 28bdae11b19189ed1998ddcfe1ed9dab56722ae774f297fb7981e2deb916f5485747932fd551549e51234bf56000b309af202601aa4fa3559879e3bc4592c3b7 SHA512 776726a9bcd868bc58f48af506c5483c2fb137713178c9be6d131285d430928691157537fc0347572868dca223a0f4b84ead9742d2d17b932642ed1b3d8c0366

View File

@@ -1,47 +0,0 @@
From d53c12962fd7250bea28e03b5a141be73cfce06b Mon Sep 17 00:00:00 2001
From: Arjan Keeman <akeeman@users.noreply.github.com>
Date: Tue, 6 Feb 2024 14:46:13 +0100
Subject: [PATCH] fix compatibility with pytest ^8
diff --git a/setup.cfg b/setup.cfg
index 45d70b3..e8cbfc5 100644
--- a/setup.cfg
+++ b/setup.cfg
@@ -40,5 +40,5 @@ include_package_data = True
install_requires =
- pytest >= 7.0.0,<8
+ pytest >= 7.0.0, !=8.0.0rc1, !=8.0.0rc2
[options.extras_require]
testing =
diff --git a/tests/markers/test_session_scope.py b/tests/markers/test_session_scope.py
index bd0baee..9049c17 100644
--- a/tests/markers/test_session_scope.py
+++ b/tests/markers/test_session_scope.py
@@ -44,7 +44,9 @@ def test_asyncio_mark_provides_session_scoped_loop_strict_mode(pytester: Pyteste
"""
),
)
- subpackage_name = "subpkg"
+
+ # subpackage_name must alphabetically come after test_module_one.py
+ subpackage_name = "z_subpkg"
subpkg = pytester.mkpydir(subpackage_name)
subpkg.joinpath("test_subpkg.py").write_text(
dedent(
diff --git a/tests/test_is_async_test.py b/tests/test_is_async_test.py
index 512243b..12e791c 100644
--- a/tests/test_is_async_test.py
+++ b/tests/test_is_async_test.py
@@ -77,8 +77,10 @@ def test_returns_false_for_unmarked_coroutine_item_in_strict_mode(pytester: Pyte
if pytest.version_tuple < (7, 2):
# Probably related to https://github.com/pytest-dev/pytest/pull/10012
result.assert_outcomes(failed=1)
- else:
+ elif pytest.version_tuple < (8,):
result.assert_outcomes(skipped=1)
+ else:
+ result.assert_outcomes(failed=1)
def test_returns_true_for_unmarked_coroutine_item_in_auto_mode(pytester: Pytester):

View File

@@ -1,16 +0,0 @@
<?xml version='1.0' encoding='UTF-8'?>
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<maintainer type="project">
<email>b@edevau.net</email>
<name>Andreas Billmeier</name>
</maintainer>
<upstream>
<remote-id type="pypi">pytest-asyncio</remote-id>
<remote-id type="github">pytest-dev/pytest-asyncio</remote-id>
<maintainer status="unknown">
<email>tinchester@gmail.com</email>
<name>Tin Tvrtković &lt;tinchester@gmail.com&gt;</name>
</maintainer>
</upstream>
</pkgmetadata>

View File

@@ -1,51 +0,0 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
DISTUTILS_USE_PEP517=setuptools
PYTHON_COMPAT=( python3_{10..12} )
inherit distutils-r1
DESCRIPTION="Library for testing asyncio code with pytest"
HOMEPAGE="
https://github.com/pytest-dev/pytest-asyncio/
https://pypi.org/project/pytest-asyncio/
"
SRC_URI="
https://github.com/pytest-dev/pytest-asyncio/archive/v${PV}.tar.gz
-> ${P}.gh.tar.gz
"
LICENSE="Apache-2.0"
SLOT="0"
KEYWORDS="amd64 arm arm64 x86"
RDEPEND="
>=dev-python/pytest-5.4.0[${PYTHON_USEDEP}]
"
BDEPEND="
dev-python/setuptools-scm[${PYTHON_USEDEP}]
test? (
dev-python/flaky[${PYTHON_USEDEP}]
>=dev-python/hypothesis-3.64[${PYTHON_USEDEP}]
)
"
distutils_enable_tests pytest
export SETUPTOOLS_SCM_PRETEND_VERSION=${PV}
EPYTEST_DESELECT=(
# rely on precise warning counts
tests/test_pytest_min_version_warning.py
tests/modes/test_legacy_mode.py
tests/trio/test_fixtures.py::test_strict_mode_ignores_trio_fixtures
)
python_test() {
local -x PYTEST_DISABLE_PLUGIN_AUTOLOAD=1
local -x PYTEST_PLUGINS=pytest_asyncio.plugin,_hypothesis_pytestplugin,flaky.flaky_pytest_plugin
epytest
}

View File

@@ -1,51 +0,0 @@
# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
DISTUTILS_USE_PEP517=setuptools
PYTHON_COMPAT=( python3_{10..12} )
inherit distutils-r1
DESCRIPTION="Library for testing asyncio code with pytest"
HOMEPAGE="
https://github.com/pytest-dev/pytest-asyncio/
https://pypi.org/project/pytest-asyncio/
"
SRC_URI="
https://github.com/pytest-dev/pytest-asyncio/archive/v${PV}.tar.gz
-> ${P}.gh.tar.gz
"
LICENSE="Apache-2.0"
SLOT="0"
KEYWORDS="amd64 arm arm64 x86"
RDEPEND="
>=dev-python/pytest-7.0.0[${PYTHON_USEDEP}]
"
BDEPEND="
dev-python/setuptools-scm[${PYTHON_USEDEP}]
test? (
dev-python/flaky[${PYTHON_USEDEP}]
>=dev-python/hypothesis-3.64[${PYTHON_USEDEP}]
)
"
distutils_enable_tests pytest
export SETUPTOOLS_SCM_PRETEND_VERSION=${PV}
EPYTEST_DESELECT=(
# rely on precise warning counts
tests/test_pytest_min_version_warning.py
tests/modes/test_legacy_mode.py
tests/trio/test_fixtures.py::test_strict_mode_ignores_trio_fixtures
)
python_test() {
local -x PYTEST_DISABLE_PLUGIN_AUTOLOAD=1
local -x PYTEST_PLUGINS=pytest_asyncio.plugin,_hypothesis_pytestplugin,flaky.flaky_pytest_plugin
epytest
}

View File

@@ -1,57 +0,0 @@
# Copyright 2019-2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
DISTUTILS_USE_PEP517=setuptools
PYPI_NO_NORMALIZE=1
PYTHON_COMPAT=( python3_{10..12} pypy3 )
inherit distutils-r1 pypi
DESCRIPTION="Library for testing asyncio code with pytest"
HOMEPAGE="
https://github.com/pytest-dev/pytest-asyncio/
https://pypi.org/project/pytest-asyncio/
"
LICENSE="Apache-2.0"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-macos"
RDEPEND="
>=dev-python/pytest-5.4.0[${PYTHON_USEDEP}]
"
BDEPEND="
dev-python/setuptools-scm[${PYTHON_USEDEP}]
test? (
>=dev-python/hypothesis-3.64[${PYTHON_USEDEP}]
)
"
distutils_enable_tests pytest
PATCHES=(
# https://github.com/pytest-dev/pytest-asyncio/pull/776
"${FILESDIR}/${P}-pytest-8.patch"
)
python_test() {
local EPYTEST_DESELECT=(
# rely on precise warning counts
tests/hypothesis/test_base.py::test_can_use_explicit_event_loop_fixture
tests/modes/test_legacy_mode.py
tests/modes/test_strict_mode.py::test_strict_mode_ignores_unmarked_fixture
tests/test_event_loop_fixture_finalizer.py::test_event_loop_fixture_finalizer_raises_warning_when_fixture_leaves_loop_unclosed
tests/test_event_loop_fixture_finalizer.py::test_event_loop_fixture_finalizer_raises_warning_when_test_leaves_loop_unclosed
tests/test_pytest_min_version_warning.py
tests/trio/test_fixtures.py::test_strict_mode_ignores_trio_fixtures
# TODO
tests/test_is_async_test.py::test_returns_false_for_unmarked_coroutine_item_in_strict_mode
)
local -x PYTEST_DISABLE_PLUGIN_AUTOLOAD=1
local -x PYTEST_PLUGINS=pytest_asyncio.plugin,_hypothesis_pytestplugin
epytest
}