[gobject-introspection] tests: Use Automake test harness instead of gtester



commit 4e88f0eb1535cffa31d8fd15ba593ac0a09b670a
Author: Simon Feltman <sfeltman src gnome org>
Date:   Sat Dec 21 16:59:22 2013 -0800

    tests: Use Automake test harness instead of gtester
    
    Switch both cmph-bdz-test and gthash_test to use the Automake test harness.
    Use EXTRA_PROGRAMS and EXTRA_LTLIBRARIES along with CLEANUP to allow lazy
    dependency evaluation of testing targets.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=720713

 Makefile-cmph.am         |    7 +++++--
 Makefile-girepository.am |    4 +++-
 Makefile.am              |    7 ++++---
 3 files changed, 12 insertions(+), 6 deletions(-)
---
diff --git a/Makefile-cmph.am b/Makefile-cmph.am
index 7bca06b..a2edcf6 100644
--- a/Makefile-cmph.am
+++ b/Makefile-cmph.am
@@ -1,4 +1,4 @@
-noinst_LTLIBRARIES += libcmph.la
+EXTRA_LTLIBRARIES += libcmph.la
 
 libcmph_la_CPPFLAGS = -Icmph $(GLIB_CFLAGS)
 libcmph_la_LIBADD = -lm $(GLIB_LIBS)
@@ -66,9 +66,12 @@ libcmph_la_SOURCES = \
        girepository/cmph/vstack.c \
        girepository/cmph/vstack.h
 
-GTESTER_PROGS += cmph-bdz-test
+
+TESTS += cmph-bdz-test
+EXTRA_PROGRAMS += cmph-bdz-test
 
 cmph_bdz_test_SOURCES = girepository/cmph-bdz-test.c
 cmph_bdz_test_CFLAGS = -I$(top_srcdir)/girepository/cmph $(GOBJECT_CFLAGS)
 cmph_bdz_test_LDADD = libcmph.la $(GOBJECT_LIBS)
 
+CLEANFILES += cmph-bdz-test libcmph.la
diff --git a/Makefile-girepository.am b/Makefile-girepository.am
index c91c41c..1f956ed 100644
--- a/Makefile-girepository.am
+++ b/Makefile-girepository.am
@@ -90,7 +90,9 @@ gi_dump_types_CFLAGS = $(GIO_UNIX_CFLAGS) $(GMODULE_CFLAGS)
 gi_dump_types_LDADD = $(GIO_UNIX_LIBS) $(GMODULE_LIBS)
 endif
 
-GTESTER_PROGS += gthash-test
+EXTRA_PROGRAMS += gthash-test
+CLEANFILES += gthash-test
+TESTS += gthash-test
 
 gthash_test_SOURCES = girepository/gthash.c girepository/gthash-test.c
 gthash_test_CFLAGS = -I$(top_srcdir)/girepository $(GOBJECT_CFLAGS)
diff --git a/Makefile.am b/Makefile.am
index 18fe091..2ec04d0 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -9,8 +9,10 @@ check_LTLIBRARIES =
 check_PROGRAMS =
 bin_PROGRAMS =
 bin_SCRIPTS =
-GTESTER_PROGS =
-noinst_PROGRAMS = $(GTESTER_PROGS)
+noinst_PROGRAMS =
+EXTRA_LTLIBRARIES =
+EXTRA_PROGRAMS =
+TESTS =
 
 include common.mk
 include Makefile.introspection
@@ -59,7 +61,6 @@ EXTRA_DIST +=                         \
 PEP8_EXCLUDES=--exclude='.svn,CVS,.bzr,.hg,.git,__pycache__,.\#*'
 
 check-local:
-       gtester --verbose $(GTESTER_PROGS)
        @echo "TEST: PEP-8 INQUISITION"
        @find $(top_srcdir)/giscanner -name \*.py | sort | uniq | xargs \
                $(PYTHON) $(top_srcdir)/misc/pep8.py --max-line-length=99 --ignore=E128 $(PEP8_EXCLUDES)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]