summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRob Staudinger <robsta@linux.intel.com>2012-01-23 14:47:40 +0100
committerRob Staudinger <robsta@linux.intel.com>2012-01-23 14:47:40 +0100
commitc041171f399d7b526543f791849199478c30173f (patch)
tree3400588116a7c4b393580a40d58a8153166d9150
parentb2d907bb744a242886277c5f8af28e063c61ffb1 (diff)
build: Run integration tests only when requested
Automatic integration tests require salut and gabble up and running on the respective system. No longer attempt to run those tests unconditionally, but only when requested using --enable-integration-tests at configure time.
-rw-r--r--Makefile.am6
-rw-r--r--configure.ac13
-rw-r--r--tests/Makefile.am5
3 files changed, 22 insertions, 2 deletions
diff --git a/Makefile.am b/Makefile.am
index e996ab0..4209d44 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,6 +1,10 @@
ACLOCAL_AMFLAGS = -I build
-DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc --enable-docs --disable-silent-rules
+DISTCHECK_CONFIGURE_FLAGS = \
+ --disable-silent-rules \
+ --enable-gtk-doc \
+ --enable-integration-tests \
+ $(NULL)
SUBDIRS = ytstenut docs tests examples
diff --git a/configure.ac b/configure.ac
index 8283caa..488bce4 100644
--- a/configure.ac
+++ b/configure.ac
@@ -11,7 +11,6 @@ AC_INIT(ytstenut, [yts_version],
AC_CONFIG_SRCDIR(ytstenut/ytstenut.h)
AC_CONFIG_AUX_DIR([build])
AC_CONFIG_MACRO_DIR([build])
-AC_SUBST(ACLOCAL_AMFLAGS, "$ACLOCAL_FLAGS -I build")
AC_SUBST(YTS_MAJOR_VERSION, yts_major_version)
AC_SUBST(YTS_MINOR_VERSION, yts_minor_version)
@@ -138,6 +137,18 @@ AC_SUBST(GLIB_GENMARSHAL)
GLIB_MKENUMS=`$PKG_CONFIG --variable=glib_mkenums glib-2.0`
AC_SUBST(GLIB_MKENUMS)
+AC_ARG_ENABLE([integration-tests],
+ [AC_HELP_STRING([--enable-integration-tests],
+ [Requires salut and gabble running, and accounts configured])],
+[
+],[
+ enable_integration_tests="no"
+])
+
+AC_MSG_CHECKING(whether to enable integration tests)
+AC_MSG_RESULT($enable_integration_tests)
+AM_CONDITIONAL(ENABLE_INTEGRATION_TESTS, test "$enable_integration_tests" = "yes")
+
AC_OUTPUT([
Makefile
docs/Makefile
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 768c54d..c230630 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -2,9 +2,14 @@
TESTS = \
message \
status \
+ $(NULL)
+
+if ENABLE_INTEGRATION_TESTS
+TESTS += \
message-send \
status-set \
$(NULL)
+endif
AM_CPPFLAGS = \
-I$(top_srcdir) \