From: "Michał Górny" <mgorny@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/pytest-cov/
Date: Sat, 01 Mar 2025 08:16:45 +0000 (UTC) [thread overview]
Message-ID: <1740816999.61febafe65f875bad8fa868bdcfad4b5ba448fbe.mgorny@gentoo> (raw)
commit: 61febafe65f875bad8fa868bdcfad4b5ba448fbe
Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Sat Mar 1 08:15:08 2025 +0000
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Sat Mar 1 08:16:39 2025 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=61febafe
dev-python/pytest-cov: Fix tests
Closes: https://bugs.gentoo.org/889886
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>
dev-python/pytest-cov/pytest-cov-6.0.0.ebuild | 28 +++++++++++++--------------
1 file changed, 13 insertions(+), 15 deletions(-)
diff --git a/dev-python/pytest-cov/pytest-cov-6.0.0.ebuild b/dev-python/pytest-cov/pytest-cov-6.0.0.ebuild
index 7a0c80e7d268..c03e424ab078 100644
--- a/dev-python/pytest-cov/pytest-cov-6.0.0.ebuild
+++ b/dev-python/pytest-cov/pytest-cov-6.0.0.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2024 Gentoo Authors
+# Copyright 1999-2025 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
@@ -7,7 +7,7 @@ DISTUTILS_USE_PEP517=setuptools
PYPI_NO_NORMALIZE=1
PYTHON_COMPAT=( python3_{10..12} pypy3 )
-inherit distutils-r1 multiprocessing pypi
+inherit distutils-r1 pypi
DESCRIPTION="pytest plugin for coverage reporting"
HOMEPAGE="
@@ -24,12 +24,13 @@ RDEPEND="
>=dev-python/pytest-3.6[${PYTHON_USEDEP}]
>=dev-python/coverage-6.4.4-r1[${PYTHON_USEDEP}]
"
+# NB: xdist is also used directly in the test suite
BDEPEND="
test? (
- dev-python/virtualenv[${PYTHON_USEDEP}]
dev-python/fields[${PYTHON_USEDEP}]
>=dev-python/process-tests-2.0.2[${PYTHON_USEDEP}]
dev-python/pytest-xdist[${PYTHON_USEDEP}]
+ dev-python/virtualenv[${PYTHON_USEDEP}]
)
"
@@ -39,6 +40,7 @@ PATCHES=(
distutils_enable_sphinx docs \
dev-python/furo
+EPYTEST_XDIST=1
distutils_enable_tests pytest
python_test() {
@@ -46,18 +48,14 @@ python_test() {
local -x PYTEST_DISABLE_PLUGIN_AUTOLOAD=1
local -x PYTEST_PLUGINS=pytest_cov.plugin,xdist.plugin,xdist.looponfail
- local src=$(
- "${EPYTHON}" -c "import coverage as m; print(*m.__path__)" || die
- )
- # TODO: why do we need to do that?!
# https://github.com/pytest-dev/pytest-cov/issues/517
- ln -s "${src}" \
- "${BUILD_DIR}/install$(python_get_sitedir)/coverage" || die
-
- nonfatal epytest -n "$(makeopts_jobs)" --dist=worksteal
- local ret=${?}
-
- rm "${BUILD_DIR}/install$(python_get_sitedir)/coverage" || die
+ local -x PYTHONPATH=$(python_get_sitedir):${PYTHONPATH}
+ local EPYTEST_DESELECT=(
+ # this one's broken by the PYTHONPATH hack
+ # the alternative is to symlink coverage and pytest into venv,
+ # but that's ugly and likely to break again in the future
+ tests/test_pytest_cov.py::test_central_subprocess_change_cwd_with_pythonpath
+ )
- [[ ${ret} -ne 0 ]] && die "epytest failed on ${EPYTHON}"
+ epytest
}
next reply other threads:[~2025-03-01 8:16 UTC|newest]
Thread overview: 102+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-03-01 8:16 Michał Górny [this message]
-- strict thread matches above, loose matches on Subject: below --
2025-03-01 8:16 [gentoo-commits] repo/gentoo:master commit in: dev-python/pytest-cov/ Michał Górny
2025-03-01 8:16 Michał Górny
2024-12-14 13:57 Arthur Zamarin
2024-04-11 19:04 Michał Górny
2024-04-11 16:35 Arthur Zamarin
2024-03-25 4:47 Michał Górny
2023-10-10 8:14 Michał Górny
2023-10-10 8:14 Michał Górny
2023-10-10 8:14 Michał Górny
2023-10-10 5:10 Michał Górny
2023-10-10 5:10 Michał Górny
2023-10-10 5:10 Michał Górny
2023-07-11 9:17 Michał Górny
2023-07-11 8:43 Jakov Smolić
2023-05-26 18:04 Michał Górny
2023-05-26 18:04 Michał Górny
2023-05-26 18:04 Michał Górny
2023-02-20 6:24 Michał Górny
2023-02-20 6:24 Michał Górny
2023-01-05 16:56 Michał Górny
2022-11-19 8:44 Arthur Zamarin
2022-11-19 8:39 Arthur Zamarin
2022-10-12 14:52 Michał Górny
2022-10-01 16:24 Michał Górny
2022-02-27 18:46 Michał Górny
2022-01-23 14:56 Michał Górny
2022-01-23 14:56 Michał Górny
2021-11-05 5:40 Arthur Zamarin
2021-11-05 2:12 Sam James
2021-10-04 8:05 Michał Górny
2021-09-21 21:37 James Le Cuirot
2021-06-23 21:27 Michał Górny
2021-06-14 22:30 Michał Górny
2021-06-14 22:18 Sam James
2021-06-01 22:44 Michał Górny
2021-05-15 8:39 Michał Górny
2021-02-24 22:30 Michał Górny
2021-02-24 22:05 Sam James
2021-02-19 8:58 Michał Górny
2021-02-19 2:54 Sam James
2021-01-30 19:31 Sam James
2021-01-21 10:52 Michał Górny
2021-01-18 11:42 Michał Górny
2021-01-18 11:42 Michał Górny
2020-12-01 10:41 Andrey Grozin
2020-11-18 8:47 Michał Górny
2020-10-16 18:22 Michał Górny
2020-08-01 21:48 Michał Górny
2020-06-16 8:18 Michał Górny
2020-03-28 18:49 Michał Górny
2020-03-28 18:49 Michał Górny
2020-03-28 18:49 Michał Górny
2020-03-26 10:19 Agostino Sarubbo
2020-03-26 8:29 Agostino Sarubbo
2020-03-25 17:44 Agostino Sarubbo
2020-03-25 16:14 Agostino Sarubbo
2020-03-25 16:12 Agostino Sarubbo
2019-12-02 21:13 Aaron Bauman
2019-11-25 12:35 Michał Górny
2019-10-12 20:23 Matt Turner
2019-04-12 13:47 Virgil Dupras
2019-04-12 13:03 Virgil Dupras
2018-12-03 12:16 Virgil Dupras
2018-11-09 13:42 Alexey Shvetsov
2018-08-14 6:41 Mart Raudsepp
2018-06-22 15:06 Mikle Kolyada
2018-05-04 15:17 Mart Raudsepp
2018-03-27 23:15 Matt Turner
2018-03-07 19:47 Markus Meier
2018-02-22 15:52 Michał Górny
2018-01-24 22:53 Sergei Trofimovich
2018-01-13 12:16 Sergei Trofimovich
2018-01-13 11:32 Sergei Trofimovich
2018-01-03 19:51 Sergei Trofimovich
2018-01-03 9:25 Michał Górny
2018-01-03 9:11 Michał Górny
2018-01-03 9:11 Michał Górny
2017-08-02 4:06 Sebastien Fabbro
2017-03-22 19:48 Markus Meier
2017-03-11 17:07 Agostino Sarubbo
2017-02-25 10:03 Agostino Sarubbo
2017-02-23 16:35 Michael Weber
2017-02-23 16:35 Michael Weber
2017-02-23 14:12 Michael Weber
2017-02-21 11:54 Tobias Klausmann
2017-02-19 8:40 Markus Meier
2017-02-12 22:20 Zac Medico
2017-02-12 17:10 Agostino Sarubbo
2017-02-12 16:25 Agostino Sarubbo
2017-02-06 14:55 Agostino Sarubbo
2017-02-04 12:08 Jeroen Roovers
2017-01-25 6:39 Jeroen Roovers
2016-02-01 16:27 Justin Lecher
2015-11-09 11:49 Justin Lecher
2015-10-15 8:57 Justin Lecher
2015-10-15 8:26 Justin Lecher
2015-10-14 17:21 Michał Górny
2015-09-29 13:03 Tobias Klausmann
2015-09-27 18:16 Justin Lecher
2015-09-22 7:02 Justin Lecher
2015-09-09 9:49 Justin Lecher
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1740816999.61febafe65f875bad8fa868bdcfad4b5ba448fbe.mgorny@gentoo \
--to=mgorny@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox