7f3bc8eac4846001059f52e7ffd1e85f1bd4cdd4
[babeltrace.git] / tests / Makefile.am
1 # SPDX-License-Identifier: MIT
2
3 SUBDIRS = \
4 utils \
5 lib \
6 bitfield \
7 ctf-writer \
8 plugins \
9 param-validation
10
11 # Directories added to EXTRA_DIST will be recursively copied to the distribution.
12 EXTRA_DIST = $(srcdir)/data \
13 bindings/python/bt2/.coveragerc
14
15 dist_check_SCRIPTS = \
16 bindings/python/bt2/test_clock_class.py \
17 bindings/python/bt2/test_component_class.py \
18 bindings/python/bt2/test_component.py \
19 bindings/python/bt2/test_connection.py \
20 bindings/python/bt2/test_event_class.py \
21 bindings/python/bt2/test_event.py \
22 bindings/python/bt2/test_field_class.py \
23 bindings/python/bt2/test_field.py \
24 bindings/python/bt2/test_graph.py \
25 bindings/python/bt2/test_integer_range_set.py \
26 bindings/python/bt2/test_interrupter.py \
27 bindings/python/bt2/test_message_iterator.py \
28 bindings/python/bt2/test_message.py \
29 bindings/python/bt2/test_package.py \
30 bindings/python/bt2/test_packet.py \
31 bindings/python/bt2/test_plugin.py \
32 bindings/python/bt2/test_port.py \
33 bindings/python/bt2/test_python_bt2 \
34 bindings/python/bt2/test_query_executor.py \
35 bindings/python/bt2/test_stream_class.py \
36 bindings/python/bt2/test_stream.py \
37 bindings/python/bt2/test_trace_collection_message_iterator.py \
38 bindings/python/bt2/test_trace.py \
39 bindings/python/bt2/test_value.py \
40 bindings/python/bt2/utils.py \
41 cli/convert/test_auto_source_discovery_grouping \
42 cli/convert/test_auto_source_discovery_params \
43 cli/convert/test_auto_source_discovery_log_level \
44 cli/convert/test_convert_args \
45 cli/list-plugins/test_list_plugins \
46 cli/params/test_params \
47 cli/query/test_query \
48 cli/test_exit_status \
49 cli/test_help \
50 cli/test_intersection \
51 cli/test_output_ctf_metadata \
52 cli/test_output_path_ctf_non_lttng_trace \
53 cli/test_packet_seq_num \
54 cli/test_trace_copy \
55 cli/test_trace_read \
56 cli/test_trimmer \
57 plugins/sink.text.details/succeed/test_succeed \
58 plugins/src.ctf.lttng-live/test_live \
59 python-plugin-provider/bt_plugin_test_python_plugin_provider.py \
60 python-plugin-provider/test_python_plugin_provider \
61 python-plugin-provider/test_python_plugin_provider.py
62
63 TESTS_BINDINGS =
64
65 if ENABLE_PYTHON_BINDINGS
66 TESTS_BINDINGS += bindings/python/bt2/test_python_bt2
67 endif
68
69 TESTS_CLI = \
70 cli/convert/test_convert_args \
71 cli/test_help \
72 cli/test_intersection \
73 cli/test_output_path_ctf_non_lttng_trace \
74 cli/test_packet_seq_num \
75 cli/test_trace_copy \
76 cli/test_trace_read \
77 cli/test_trimmer
78
79 TESTS_LIB = \
80 lib/test_bt_uuid \
81 lib/test_bt_values \
82 lib/test_graph_topo \
83 lib/test_remove_destruction_listener_in_destruction_listener \
84 lib/test_simple_sink \
85 lib/test_trace_ir_ref
86
87 TESTS_BITFIELD = \
88 bitfield/test_bitfield
89
90 TESTS_CTF_WRITER = \
91 ctf-writer/test_ctf_writer
92
93 if !ENABLE_BUILT_IN_PLUGINS
94 TESTS_LIB += lib/test_plugin
95 endif
96
97 TESTS_PLUGINS = \
98 plugins/src.ctf.fs/fail/test_fail \
99 plugins/src.ctf.fs/succeed/test_succeed \
100 plugins/src.ctf.fs/test_deterministic_ordering \
101 plugins/sink.ctf.fs/succeed/test_succeed \
102 plugins/sink.text.details/succeed/test_succeed
103
104 if !ENABLE_BUILT_IN_PLUGINS
105 if ENABLE_PYTHON_BINDINGS
106 TESTS_PLUGINS += plugins/src.ctf.fs/query/test_query_support_info
107 TESTS_PLUGINS += plugins/src.ctf.fs/query/test_query_trace_info
108 TESTS_PLUGINS += plugins/src.ctf.fs/query/test_query_metadata_info
109 endif
110 endif
111
112 if ENABLE_DEBUG_INFO
113 TESTS_PLUGINS += \
114 plugins/flt.lttng-utils.debug-info/test_dwarf_i386-linux-gnu \
115 plugins/flt.lttng-utils.debug-info/test_dwarf_powerpc-linux-gnu \
116 plugins/flt.lttng-utils.debug-info/test_dwarf_powerpc64le-linux-gnu \
117 plugins/flt.lttng-utils.debug-info/test_dwarf_x86_64-linux-gnu \
118 plugins/flt.lttng-utils.debug-info/test_bin_info_i386-linux-gnu \
119 plugins/flt.lttng-utils.debug-info/test_bin_info_powerpc-linux-gnu \
120 plugins/flt.lttng-utils.debug-info/test_bin_info_powerpc64le-linux-gnu \
121 plugins/flt.lttng-utils.debug-info/test_bin_info_x86_64-linux-gnu
122 endif
123
124 if ENABLE_PYTHON_PLUGINS
125 if ENABLE_PYTHON_BINDINGS
126 TESTS_CLI += \
127 cli/convert/test_auto_source_discovery_grouping \
128 cli/convert/test_auto_source_discovery_log_level \
129 cli/convert/test_auto_source_discovery_params \
130 cli/list-plugins/test_list_plugins \
131 cli/params/test_params \
132 cli/query/test_query \
133 cli/test_exit_status
134
135 TESTS_PLUGINS += plugins/flt.utils.trimmer/test_trimming \
136 plugins/flt.utils.muxer/succeed/test_succeed
137 endif
138 endif
139
140 if HAVE_PYTHON
141 TESTS_PLUGINS += plugins/src.ctf.lttng-live/test_live
142 endif
143
144 TESTS_PYTHON_PLUGIN_PROVIDER =
145
146 if ENABLE_PYTHON_PLUGINS
147 TESTS_PYTHON_PLUGIN_PROVIDER += python-plugin-provider/test_python_plugin_provider
148 if ENABLE_DEBUG_INFO
149 TESTS_PLUGINS += \
150 plugins/flt.lttng-utils.debug-info/test_succeed
151 endif
152 endif
153
154 TESTS_PARAM_VALIDATION = \
155 param-validation/test_param_validation
156
157 LOG_DRIVER_FLAGS = --merge --comments
158 LOG_DRIVER = env AM_TAP_AWK='$(AWK)' \
159 BT_TESTS_SRCDIR='$(abs_top_srcdir)/tests' \
160 BT_TESTS_BUILDDIR='$(abs_top_builddir)/tests' \
161 BT_TESTS_AWK_BIN="$(AWK)" \
162 BT_TESTS_GREP_BIN="$(GREP)" \
163 BT_TESTS_PYTHON_BIN="$(PYTHON)" \
164 BT_TESTS_PYTHON_CONFIG_BIN="$(PYTHON_CONFIG)" \
165 BT_TESTS_SED_BIN="$(SED)" \
166 $(SHELL) $(srcdir)/utils/tap-driver.sh
167
168 TESTS_NO_BITFIELD = \
169 $(TESTS_BINDINGS) \
170 $(TESTS_CLI) \
171 $(TESTS_CTF_WRITER) \
172 $(TESTS_LIB) \
173 $(TESTS_PARAM_VALIDATION) \
174 $(TESTS_PLUGINS) \
175 $(TESTS_PYTHON_PLUGIN_PROVIDER)
176
177 TESTS = $(TESTS_NO_BITFIELD) $(TESTS_BITFIELD)
178
179 define check_target
180 check-$(1):
181 $(MAKE) $(AM_MAKEFLAGS) TESTS="$2" check
182 endef
183
184 $(eval $(call check_target,bindings,$(TESTS_BINDINGS)))
185 $(eval $(call check_target,bitfield,$(TESTS_BITFIELD)))
186 $(eval $(call check_target,cli,$(TESTS_CLI)))
187 $(eval $(call check_target,ctf-writer,$(TESTS_CTF_WRITER)))
188 $(eval $(call check_target,lib,$(TESTS_LIB)))
189 $(eval $(call check_target,plugins,$(TESTS_PLUGINS)))
190 $(eval $(call check_target,python-plugin-provider,$(TESTS_PYTHON_PLUGIN_PROVIDER)))
191
192 check-no-bitfield:
193 $(MAKE) $(AM_MAKEFLAGS) TESTS="$(TESTS_NO_BITFIELD)" check
This page took 0.03435 seconds and 3 git commands to generate.