Introduce Queue and Deque interfaces, and implement them in LinkedList
[platform/upstream/libgee.git] / tests / Makefile.am
1 include $(top_srcdir)/Makefile.decl
2
3 NULL =
4
5 AM_CPPFLAGS = \
6         -I$(top_srcdir)/gee \
7         $(GLIB_CFLAGS) \
8         $(NULL)
9
10 noinst_PROGRAMS = $(TEST_PROGS)
11
12 progs_ldadd = $(GLIB_LIBS) ../gee/libgee.la
13
14 BUILT_SOURCES = tests.vala.stamp
15
16 TEST_PROGS += tests
17 tests_VALASOURCES = \
18        testarraylist.vala \
19        testcase.vala \
20        testcollection.vala \
21        testdeque.vala \
22        testhashmultimap.vala \
23        testhashmultiset.vala \
24        testlinkedlist.vala \
25        testlinkedlistasdeque.vala \
26        testlist.vala \
27        testmain.vala \
28        testmultimap.vala \
29        testmultiset.vala \
30        testqueue.vala \
31        testreadonlycollection.vala \
32        testreadonlylist.vala \
33        $(NULL)
34
35 tests_SOURCES = tests.vala.stamp $(tests_VALASOURCES:.vala=.c)
36 tests.vala.stamp: $(tests_VALASOURCES)
37         $(VALAC) -C --basedir $(top_srcdir) --vapidir $(top_srcdir)/gee --pkg gee-1.0 $^
38         touch $@
39 tests_LDADD = $(progs_ldadd)
40 EXTRA_DIST += $(tests_VALASOURCES)
41
42 coverage-reset:
43         lcov --base-directory=@top_srcdir@ --directory @top_srcdir@/gee --zerocounters
44
45 coverage-report:
46         lcov --directory @top_srcdir@/gee \
47                 --capture \
48                 --output-file @top_builddir@/lcov.info
49
50         lcov --directory @top_srcdir@/gee \
51                 --output-file @top_builddir@/lcov.info \
52                 --remove @top_builddir@/lcov.info \
53                 /usr/include/\*
54
55         $(mkdir_p) @top_builddir@/tests/coverage
56         git_commit=`GIT_DIR=@top_srcdir@/.git git log -1 --pretty=format:%h 2>/dev/null`;\
57         genhtml --title "@PACKAGE_STRING@ $$git_commit" \
58                 --output-directory @top_builddir@/tests/coverage @top_builddir@/lcov.info
59         @echo
60         @echo 'lcov report can be found in:'
61         @echo 'file://@abs_top_builddir@/tests/coverage/index.html'
62         @echo
63
64 clean-local:
65         -rm -rf coverage
66
67 .PHONY: coverage-report
68
69 TEST_PROGS += testhashmap
70 testhashmap_VALASOURCES = testhashmap.vala
71 testhashmap_SOURCES = testhashmap.c
72 $(testhashmap_SOURCES): $(testhashmap_VALASOURCES)
73         $(VALAC) -C --basedir $(top_srcdir) --vapidir $(top_srcdir)/gee --pkg gee-1.0 $^
74         touch $@
75 testhashmap_LDADD = $(progs_ldadd)
76 EXTRA_DIST += $(testhashmap_VALASOURCES)
77
78 TEST_PROGS += testhashset
79 testhashset_VALASOURCES = testhashset.vala
80 testhashset_SOURCES = testhashset.c
81 $(testhashset_SOURCES): $(testhashset_VALASOURCES)
82         $(VALAC) -C --basedir $(top_srcdir) --vapidir $(top_srcdir)/gee --pkg gee-1.0 $^
83         touch $@
84 testhashset_LDADD = $(progs_ldadd)
85 EXTRA_DIST += $(testhashset_VALASOURCES)
86
87 TEST_PROGS += testtreeset
88 testtreeset_VALASOURCES = testtreeset.vala
89 testtreeset_SOURCES = testtreeset.c testtreeset.h
90 $(testtreeset_SOURCES): $(testtreeset_VALASOURCES)
91         $(VALAC) -C --basedir $(top_srcdir) --vapidir $(top_srcdir)/gee --pkg gee-1.0 $^
92         touch $@
93 testtreeset_LDADD = $(progs_ldadd)
94 EXTRA_DIST += $(testtreeset_VALASOURCES)
95
96 TEST_PROGS += testtreemap
97 testtreemap_VALASOURCES = testtreemap.vala
98 testtreemap_SOURCES = testtreemap.c testtreemap.h
99 $(testtreemap_SOURCES): $(testtreemap_VALASOURCES)
100         $(VALAC) -C --basedir $(top_srcdir) --vapidir $(top_srcdir)/gee --pkg gee-1.0 $^
101         touch $@
102 testtreemap_LDADD = $(progs_ldadd)
103 EXTRA_DIST += $(testtreemap_VALASOURCES)
104