distutils-r1.eclass: Skip dep on ${PN} in EPYTEST_PLUGINS

When `EPYTEST_PLUGINS` contains `${PN}`, skip it when adding
dependencies.  This avoids a self-dependency, while making it possible
to easily test pytest plugins themselves without having to append to
`EPYTEST_PLUGINS` locally.

Signed-off-by: Michał Górny <mgorny@gentoo.org>
Part-of: https://github.com/gentoo/gentoo/pull/43007
Signed-off-by: Michał Górny <mgorny@gentoo.org>
This commit is contained in:
Michał Górny
2025-07-15 07:00:20 +02:00
parent 54766f55ba
commit 5d977ed349

View File

@@ -565,6 +565,10 @@ distutils_enable_tests() {
_set_epytest_plugins
for plugin in "${EPYTEST_PLUGINS[@]}"; do
case ${plugin} in
${PN})
# don't add a dependency on self
continue
;;
pkgcore)
plugin=sys-apps/${plugin}
;;