From ba21a080dee58f925d095f3a6b6156719923cb27 Mon Sep 17 00:00:00 2001 From: Rex Dieter Date: Sep 01 2015 16:39:07 +0000 Subject: enable -DKDE4_BUILD_TESTS:BOOL=ON to workaround cmake failures otherwise --- diff --git a/.gitignore b/.gitignore index 2952da8..d9c2c98 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,2 @@ -/kde-baseapps-15.04.2.tar.xz /kde-baseapps-15.04.3.tar.xz /kde-baseapps-15.08.0.tar.xz diff --git a/kde-baseapps.spec b/kde-baseapps.spec index 3a6d97b..3cc232e 100644 --- a/kde-baseapps.spec +++ b/kde-baseapps.spec @@ -6,6 +6,9 @@ %define folderview 1 %endif +# enable tests +%global tests 1 + Name: kde-baseapps Summary: KDE Core Applications Version: 15.08.0 @@ -76,6 +79,12 @@ BuildRequires: pkgconfig(glib-2.0) BuildRequires: pkgconfig(xrender) BuildRequires: pkgconfig(zlib) +%if 0%{?tests} +%global _kde4_build_tests -DKDE4_BUILD_TESTS:BOOL=ON +# %%%check +BuildRequires: dbus-x11 xorg-x11-server-Xvfb +%endif + Requires: %{name}-common = %{version}-%{release} %if 0%{?folderview} Requires: kde-plasma-folderview = 6:%{version}-%{release} @@ -331,6 +340,11 @@ done %check +%if 0%{?tests} +export CTEST_OUTPUT_ON_FAILURE=1 +# setting semi-arbitrary 30 second timeout, KonqPopupMenuTest, seems to hang or take a really long time --rex +time xvfb-run -a dbus-launch --exit-with-session make -C %{_target_platform}/ test ARGS="--output-on-failure --timeout 30" ||: +%endif appstream-util validate-relax --nonet %{buildroot}%{_datadir}/appdata/kfind.appdata.xml ||: appstream-util validate-relax --nonet %{buildroot}%{_datadir}/appdata/konqueror.appdata.xml ||: for f in %{buildroot}%{_kde4_datadir}/applications/kde4/*.desktop ; do