summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichał Górny <mgorny@gentoo.org>2020-09-20 16:47:04 +0200
committerMichał Górny <mgorny@gentoo.org>2020-09-20 16:56:45 +0200
commita07e2a8c90a4307ef9eccd6c7605568eb692a0f1 (patch)
treed259a7e6451c2750f820861fee2eb1d18d591ae5 /dev-python/pygobject
parentdev-python/six: Skip tests on py2 (diff)
downloadgentoo-a07e2a8c90a4307ef9eccd6c7605568eb692a0f1.tar.gz
gentoo-a07e2a8c90a4307ef9eccd6c7605568eb692a0f1.tar.bz2
gentoo-a07e2a8c90a4307ef9eccd6c7605568eb692a0f1.zip
dev-python/pygobject: Skip tests on py2
Signed-off-by: Michał Górny <mgorny@gentoo.org>
Diffstat (limited to 'dev-python/pygobject')
-rw-r--r--dev-python/pygobject/pygobject-3.34.0.ebuild18
-rw-r--r--dev-python/pygobject/pygobject-3.36.1.ebuild18
2 files changed, 26 insertions, 10 deletions
diff --git a/dev-python/pygobject/pygobject-3.34.0.ebuild b/dev-python/pygobject/pygobject-3.34.0.ebuild
index d7583e57c7bb..daaf30dc04df 100644
--- a/dev-python/pygobject/pygobject-3.34.0.ebuild
+++ b/dev-python/pygobject/pygobject-3.34.0.ebuild
@@ -27,11 +27,14 @@ RDEPEND="${PYTHON_DEPS}
"
DEPEND="${RDEPEND}
test? (
- dev-libs/atk[introspection]
- dev-python/pytest[${PYTHON_USEDEP}]
- x11-libs/gdk-pixbuf:2[introspection,jpeg]
- x11-libs/gtk+:3[introspection]
- x11-libs/pango[introspection] )
+ $(python_gen_cond_dep '
+ dev-libs/atk[introspection]
+ dev-python/pytest[${PYTHON_USEDEP}]
+ x11-libs/gdk-pixbuf:2[introspection,jpeg]
+ x11-libs/gtk+:3[introspection]
+ x11-libs/pango[introspection]
+ ' -3)
+ )
"
BDEPEND="
virtual/pkgconfig
@@ -59,6 +62,11 @@ src_test() {
local -x GIO_USE_VOLUME_MONITOR="unix" # prevent udisks-related failures in chroots, bug #449484
testing() {
+ if ! python_is_python3; then
+ einfo "Skipping tests on Python 2 to unblock deps"
+ return
+ fi
+
local -x XDG_CACHE_HOME="${T}/${EPYTHON}"
meson_src_test || die "test failed for ${EPYTHON}"
}
diff --git a/dev-python/pygobject/pygobject-3.36.1.ebuild b/dev-python/pygobject/pygobject-3.36.1.ebuild
index b4bc8e3bab46..16c018529420 100644
--- a/dev-python/pygobject/pygobject-3.36.1.ebuild
+++ b/dev-python/pygobject/pygobject-3.36.1.ebuild
@@ -27,11 +27,14 @@ RDEPEND="${PYTHON_DEPS}
"
DEPEND="${RDEPEND}
test? (
- dev-libs/atk[introspection]
- dev-python/pytest[${PYTHON_USEDEP}]
- x11-libs/gdk-pixbuf:2[introspection,jpeg]
- x11-libs/gtk+:3[introspection]
- x11-libs/pango[introspection] )
+ $(python_gen_cond_dep '
+ dev-libs/atk[introspection]
+ dev-python/pytest[${PYTHON_USEDEP}]
+ x11-libs/gdk-pixbuf:2[introspection,jpeg]
+ x11-libs/gtk+:3[introspection]
+ x11-libs/pango[introspection]
+ ' -3)
+ )
"
BDEPEND="
virtual/pkgconfig
@@ -59,6 +62,11 @@ src_test() {
local -x GIO_USE_VOLUME_MONITOR="unix" # prevent udisks-related failures in chroots, bug #449484
testing() {
+ if ! python_is_python3; then
+ einfo "Skipping tests on Python 2 to unblock deps"
+ return
+ fi
+
local -x XDG_CACHE_HOME="${T}/${EPYTHON}"
meson_src_test || die "test failed for ${EPYTHON}"
}