commit:     d947850c343369d9842bf8a582033b5662014a10
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Fri Mar 29 08:18:24 2024 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Wed Apr  3 05:10:34 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d947850c

dev-libs/libindicate: wire up tests

Includs some XFAILs but it's better than nothing.

Signed-off-by: Sam James <sam <AT> gentoo.org>

 .../files/libindicate-12.10.1-tests-werror.patch   | 47 ++++++++++++++++++++++
 dev-libs/libindicate/libindicate-12.10.1-r4.ebuild | 18 ++++++---
 2 files changed, 60 insertions(+), 5 deletions(-)

diff --git a/dev-libs/libindicate/files/libindicate-12.10.1-tests-werror.patch 
b/dev-libs/libindicate/files/libindicate-12.10.1-tests-werror.patch
new file mode 100644
index 000000000000..1f669dbc5ec5
--- /dev/null
+++ b/dev-libs/libindicate/files/libindicate-12.10.1-tests-werror.patch
@@ -0,0 +1,47 @@
+--- a/examples/Makefile.am
++++ b/examples/Makefile.am
+@@ -20,7 +20,7 @@ indicate_and_crash_SOURCES = \
+ 
+ indicate_and_crash_CFLAGS = \
+       -I $(srcdir)/.. \
+-      -Wall -Werror \
++      -Wall \
+       $(LIBINDICATE_CFLAGS)
+ 
+ indicate_and_crash_LDADD = \
+@@ -32,7 +32,7 @@ indicate_alot_SOURCES = \
+ 
+ indicate_alot_CFLAGS = \
+       -I $(srcdir)/.. \
+-      -Wall -Werror \
++      -Wall \
+       $(LIBINDICATE_CFLAGS)
+ 
+ indicate_alot_LDADD = \
+@@ -44,7 +44,7 @@ listen_and_print_SOURCES = \
+ 
+ listen_and_print_CFLAGS = \
+       -I $(srcdir)/.. \
+-      -Wall -Werror \
++      -Wall \
+       $(LIBINDICATE_CFLAGS) \
+       $(LIBINDICATEGTK_CFLAGS)
+ 
+@@ -59,7 +59,7 @@ im_client_SOURCES = \
+ 
+ im_client_CFLAGS = \
+       -I $(srcdir)/.. \
+-      -Wall -Werror \
++      -Wall \
+       $(LIBINDICATE_CFLAGS) \
+       $(LIBINDICATEGTK_CFLAGS)
+ 
+@@ -74,7 +74,7 @@ show_hide_server_SOURCES = \
+ 
+ show_hide_server_CFLAGS = \
+       -I $(srcdir)/.. \
+-      -Wall -Werror \
++      -Wall \
+       $(LIBINDICATE_CFLAGS)
+ 
+ show_hide_server_LDADD = \

diff --git a/dev-libs/libindicate/libindicate-12.10.1-r4.ebuild 
b/dev-libs/libindicate/libindicate-12.10.1-r4.ebuild
index 0bf3a2211de3..f4d947713309 100644
--- a/dev-libs/libindicate/libindicate-12.10.1-r4.ebuild
+++ b/dev-libs/libindicate/libindicate-12.10.1-r4.ebuild
@@ -14,8 +14,8 @@ 
SRC_URI="https://launchpad.net/${PN}/${PV%.*}/${PV}/+download/${P}.tar.gz";
 LICENSE="LGPL-2.1 LGPL-3"
 SLOT="3"
 KEYWORDS="~alpha amd64 arm arm64 ~hppa ~mips ppc ppc64 ~riscv sparc x86"
-IUSE="gtk +introspection"
-RESTRICT="test" # consequence of the -no-mono.patch
+IUSE="gtk +introspection test"
+RESTRICT="!test? ( test )"
 
 RDEPEND="
        dev-libs/dbus-glib
@@ -35,9 +35,13 @@ BDEPEND="
        gnome-base/gnome-common
        virtual/pkgconfig
        $(vala_depend)
+       test? ( dev-util/dbus-test-runner )
 "
 
-PATCHES=( "${FILESDIR}"/${P}-autotools.patch )
+PATCHES=(
+       "${FILESDIR}"/${P}-autotools.patch
+       "${FILESDIR}"/${PN}-12.10.1-tests-werror.patch
+)
 
 src_prepare() {
        default
@@ -51,10 +55,14 @@ src_configure() {
        econf \
                $(use_enable gtk) \
                $(use_enable introspection) \
+               $(use_enable test tests) \
                --disable-python \
                --disable-scrollkeeper \
-               --with-gtk=3 \
-               --disable-tests
+               --with-gtk=3
+}
+
+src_test() {
+       emake check XFAIL_TESTS="test-interests test-interests-multi 
test-max-indicators test-indicator-display test-indicator-display-half"
 }
 
 src_install() {

Reply via email to