commit:     df1f6ef9804478408502465389ddc88579dfe1d5
Author:     Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Thu Apr 24 13:26:20 2025 +0000
Commit:     Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Thu Apr 24 13:26:20 2025 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=df1f6ef9

dev-python/translate-toolkit: Deselect tests on deps instead of USE

Ignore specific tests if the user does not have the necessary
dependencies installed, rather than based on whether the USE flags
corresponding to the dependency were selected.  This should improve
test coverage on arch testing systems.

Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>

 dev-python/translate-toolkit/translate-toolkit-3.15.1-r1.ebuild | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/dev-python/translate-toolkit/translate-toolkit-3.15.1-r1.ebuild 
b/dev-python/translate-toolkit/translate-toolkit-3.15.1-r1.ebuild
index a07051c4d28f..d6401696b727 100644
--- a/dev-python/translate-toolkit/translate-toolkit-3.15.1-r1.ebuild
+++ b/dev-python/translate-toolkit/translate-toolkit-3.15.1-r1.ebuild
@@ -66,7 +66,7 @@ src_test() {
        # correctly, so we need to reassemble all data files in a single 
directory
        local -x XDG_DATA_HOME=${T}/share
        cp -r translate/share "${T}/" || die
-       cp -r "${ESYSROOT}/usr/share"/gaupol "${XDG_DATA_HOME}"/ || die
+       cp -r "${ESYSROOT}"/usr/share/gaupol "${XDG_DATA_HOME}"/ || die
 
        distutils-r1_src_test
 }
@@ -88,14 +88,14 @@ python_test() {
                tests/odf_xliff/test_odf_xliff.py
        )
 
-       if ! use ini; then
+       if ! has_version "dev-python/iniparse[${PYTHON_USEDEP}]"; then
                EPYTEST_IGNORE+=(
                        translate/convert/test_ini2po.py
                        translate/convert/test_po2ini.py
                )
        fi
 
-       if ! use subtitles; then
+       if ! has_version "media-video/gaupol[${PYTHON_USEDEP}]"; then
                EPYTEST_IGNORE+=(
                        translate/storage/test_subtitles.py
                )

Reply via email to