Statistics
| Revision:

root / trunk / tests / Makefile.am @ 1863

History | View | Annotate | Download (3.6 KB)

1
include $(top_srcdir)/Makefile.decl
2

                
3
if BUILD_TESTSUITE
4
noinst_PROGRAMS = test_schedular test_regex test_jsonrpc test_download_queue
5

                
6
if ENABLE_ONLINE_TESTS
7
noinst_PROGRAMS += test_nzbcreator test_nntpconnection_backend
8
endif
9

                
10
INCLUDES = $(GLIB_CFLAGS) $(GIO_CFLAGS) $(LIBPROXY_CFLAGS) $(OPENSSL_CFLAGS) $(NSS_CFLAGS) $(GNUTLS_CFLAGS) $(LIBPROXY_CFLAGS) -I$(top_srcdir)/base -I$(top_srcdir)/plugins -I$(top_srcdir)/nntpgrab_core
11
AM_CFLAGS = -Wall
12

                
13
# The testcases test_nntp_connection and test_configuration require the
14
# use of private functions in the NNTPGrab Core. These are disabled for now
15
if FALSE
16
noinst_PROGRAMS += test_nntp_connection test_configuration
17
endif
18

                
19
# The testcases test_par2 and test_unpack don't compile on Mac OS X
20
if DARWIN
21
else
22
noinst_PROGRAMS += test_par2 test_unpack
23
endif
24

                
25
if FALSE
26
test_nntp_connection_LDADD = $(top_srcdir)/nntpgrab_core/libnntpgrab.la
27
test_nntp_connection_SOURCES = test_nntp_connection.c
28

                
29
test_configuration_LDADD = $(top_srcdir)/nntpgrab_core/libnntpgrab.la
30
test_configuration_SOURCES = test_configuration.c
31
endif
32

                
33
test_schedular_LDADD = $(top_srcdir)/nntpgrab_core/libnntpgrab.la
34
test_schedular_SOURCES = test_schedular.c
35

                
36
test_regex_LDADD = $(top_srcdir)/base/libnntpgrab_utils.la
37
test_regex_SOURCES = test_regex.c
38

                
39
test_par2_CPPFLAGS = -I$(top_srcdir)/plugins/par2
40
test_par2_LDADD = $(top_srcdir)/plugins/par2/libnntpgrab_plugin_par2.la
41
test_par2_SOURCES = test_par2.c
42

                
43
test_unpack_CPPFLAGS = -I$(top_srcdir)/plugins/unpack
44
test_unpack_LDADD = $(top_srcdir)/plugins/unpack/libnntpgrab_plugin_unpack.la
45
test_unpack_SOURCES = test_unpack.c
46

                
47
if ENABLE_ONLINE_TESTS
48
test_nzbcreator_LDADD = $(top_srcdir)/base/libnntpgrab_utils.la
49
test_nzbcreator_SOURCES = test_nzbcreator.c
50

                
51
test_nntpconnection_backend_LDADD = $(GLIB_LIBS) $(GIO_LIBS) $(LIBPROXY_LIBS) $(OPENSSL_LIBS) $(NSS_LIBS) $(GNUTLS_LIBS) $(LIBPROXY_LIBS)
52
test_nntpconnection_backend_SOURCES =    test_nntpconnection_backend.c \
53
                                        $(top_srcdir)/nntpgrab_core/nntpconnection_utils.c \
54
                                        $(top_srcdir)/nntpgrab_core/nntpconnection_backend_iface.c \
55
                                        $(top_srcdir)/nntpgrab_core/nntpconnection_backend_gio.c \
56
                                        $(top_srcdir)/nntpgrab_core/nntpconnection_backend_native.c
57

                
58
TEST_PROGS += test_nzbcreator test_nntpconnection_backend
59
endif
60

                
61
test_jsonrpc_CFLAGS = -I$(top_srcdir)/plugins/jsonrpc
62
test_jsonrpc_LDADD = $(GLIB_LIBS)
63
test_jsonrpc_SOURCES =   test_jsonrpc.c \
64
                 $(top_srcdir)/plugins/jsonrpc/arraylist.c \
65
                 $(top_srcdir)/plugins/jsonrpc/circular_buffer.c \
66
                 $(top_srcdir)/plugins/jsonrpc/debug.c \
67
                 $(top_srcdir)/plugins/jsonrpc/hashmap.c \
68
                 $(top_srcdir)/plugins/jsonrpc/json_object.c \
69
                 $(top_srcdir)/plugins/jsonrpc/json_tokener.c \
70
                 $(top_srcdir)/plugins/jsonrpc/json_util.c \
71
                 $(top_srcdir)/plugins/jsonrpc/jsonrpc.c \
72
                 $(top_srcdir)/plugins/jsonrpc/linkhash.c \
73
                 $(top_srcdir)/plugins/jsonrpc/printbuf.c
74

                
75
test_download_queue_CFLAGS = -DDOWNLOAD_QUEUE_DONT_SET_TMP_FILENAME
76
test_download_queue_LDADD = $(GLIB_LIBS) $(top_srcdir)/base/libnntpgrab_utils.la
77
test_download_queue_SOURCES =    test_download_queue.c \
78
                         test_download_queue_one_server.c \
79
                         test_download_queue_two_servers.c \
80
                         common.c \
81
                         $(top_srcdir)/nntpgrab_core/core_signals.c \
82
                         $(top_srcdir)/nntpgrab_core/collection_alloc.c \
83
                         $(top_srcdir)/nntpgrab_core/configuration.c \
84
                         $(top_srcdir)/nntpgrab_core/download_queue.c \
85
                         $(top_srcdir)/nntpgrab_core/queue_rawfile.c
86

                
87
TEST_PROGS += test_jsonrpc test_download_queue
88

                
89
endif
90

                
91
noinst_HEADERS = common.h test_download_queue.h
92

                
93
EXTRA_DIST = download_queue_with_1_file.db valgrind.supp
94