From df11b267fd2981d0796c0ec25bfd4674ca805aec Mon Sep 17 00:00:00 2001 From: Lubomir Rintel Date: Thu, 14 May 2015 14:45:45 +0200 Subject: [PATCH] build: switch to parallel test harness This will make it possible to use the TAP formatter. (cherry picked from commit 380ed633180a1e20cb70b2cfde482a1cda8278e0) --- .gitignore | 2 ++ configure.ac | 17 ++--------------- libnm-glib/tests/Makefile.am | 2 +- libnm/tests/Makefile.am | 2 +- 4 files changed, 6 insertions(+), 17 deletions(-) diff --git a/.gitignore b/.gitignore index a0511491b8..834be29407 100644 --- a/.gitignore +++ b/.gitignore @@ -28,6 +28,8 @@ gtk-doc.make *.pc cscope.*out valgrind-*.log +test-*.log +test-*.trs *-glue.h /ABOUT-NLS diff --git a/configure.ac b/configure.ac index 5f1b62e088..44292e1ad8 100644 --- a/configure.ac +++ b/configure.ac @@ -16,20 +16,7 @@ AC_CONFIG_HEADERS([config.h]) AC_CONFIG_MACRO_DIR([m4]) AC_CONFIG_AUX_DIR([build-aux]) -dnl Initialize automake. automake < 1.12 didn't have serial-tests and -dnl gives an error if it sees this, but for automake >= 1.13 -dnl serial-tests is required so we have to include it. Solution is to -dnl test for the version of automake (by running an external command) -dnl and provide it if necessary. Note we have to do this entirely using -dnl m4 macros since automake queries this macro by running -dnl 'autoconf --trace ...'. -m4_define([serial_tests], [ - m4_esyscmd([automake --version | - head -1 | - awk '{split ($NF,a,"."); if (a[1] == 1 && a[2] >= 12) { print "serial-tests" }}' - ]) -]) -AM_INIT_AUTOMAKE(1.11 serial_tests tar-ustar no-dist-gzip dist-bzip2 -Wno-portability) dnl NB: Do not [quote] this parameter. +AM_INIT_AUTOMAKE(1.12 tar-ustar no-dist-gzip dist-bzip2 -Wno-portability) dnl NB: Do not [quote] this parameter. AM_MAINTAINER_MODE([enable]) AM_SILENT_RULES([yes]) @@ -880,7 +867,7 @@ else fi fi AS_IF([test "$with_valgrind" != "no"], - AC_SUBST(VALGRIND_RULES, 'TESTS_ENVIRONMENT = "$(top_srcdir)/tools/run-test-valgrind.sh" "$(LIBTOOL)" "$(with_valgrind)" '"$with_valgrind_suppressions"), + AC_SUBST(VALGRIND_RULES, 'LOG_COMPILER = "$(top_srcdir)/tools/run-test-valgrind.sh" "$(LIBTOOL)" "$(with_valgrind)" '"$with_valgrind_suppressions"), AC_SUBST(VALGRIND_RULES, [])) AM_CONDITIONAL(WITH_VALGRIND, test "${with_valgrind}" != "no") diff --git a/libnm-glib/tests/Makefile.am b/libnm-glib/tests/Makefile.am index cea3b79a74..7168d3dd15 100644 --- a/libnm-glib/tests/Makefile.am +++ b/libnm-glib/tests/Makefile.am @@ -15,7 +15,7 @@ noinst_PROGRAMS = $(TESTS) if WITH_VALGRIND @VALGRIND_RULES@ --launch-dbus else -TESTS_ENVIRONMENT = $(srcdir)/libnm-glib-test-launch.sh +LOG_COMPILER = $(srcdir)/libnm-glib-test-launch.sh endif TESTS = test-nm-client test-remote-settings-client diff --git a/libnm/tests/Makefile.am b/libnm/tests/Makefile.am index 56dd17d5f8..a2dafec768 100644 --- a/libnm/tests/Makefile.am +++ b/libnm/tests/Makefile.am @@ -20,7 +20,7 @@ noinst_PROGRAMS = $(TESTS) if WITH_VALGRIND @VALGRIND_RULES@ --launch-dbus else -TESTS_ENVIRONMENT = $(srcdir)/libnm-test-launch.sh +LOG_COMPILER = $(srcdir)/libnm-test-launch.sh endif TESTS = test-nm-client test-remote-settings-client test-secret-agent