tests/plugins/flt.utils.muxer: add test for clock (in)compatibility cases
[babeltrace.git] / tests / Makefile.am
1 # SPDX-License-Identifier: MIT
2
3 include $(top_srcdir)/src/Makefile.common.inc
4
5 SUBDIRS = \
6 utils \
7 lib \
8 bitfield \
9 ctf-writer \
10 plugins \
11 param-validation
12
13 AM_CPPFLAGS += -I$(top_srcdir)/tests/utils
14
15 COMMON_TEST_LDADD = \
16 $(top_builddir)/tests/utils/tap/libtap.la \
17 $(top_builddir)/src/common/libcommon.la \
18 $(top_builddir)/src/logging/liblogging.la
19
20 # Directories added to EXTRA_DIST will be recursively copied to the distribution.
21 EXTRA_DIST = $(srcdir)/data \
22 bindings/python/bt2/.coveragerc
23
24 dist_check_SCRIPTS = \
25 bindings/python/bt2/test-python-bt2.sh \
26 bindings/python/bt2/test_clock_class.py \
27 bindings/python/bt2/test_component_class.py \
28 bindings/python/bt2/test_component.py \
29 bindings/python/bt2/test_connection.py \
30 bindings/python/bt2/test_event_class.py \
31 bindings/python/bt2/test_event.py \
32 bindings/python/bt2/test_field_class.py \
33 bindings/python/bt2/test_field.py \
34 bindings/python/bt2/test_graph.py \
35 bindings/python/bt2/test_integer_range_set.py \
36 bindings/python/bt2/test_interrupter.py \
37 bindings/python/bt2/test_message_iterator.py \
38 bindings/python/bt2/test_message.py \
39 bindings/python/bt2/test_package.py \
40 bindings/python/bt2/test_packet.py \
41 bindings/python/bt2/test_plugin.py \
42 bindings/python/bt2/test_port.py \
43 bindings/python/bt2/test_query_executor.py \
44 bindings/python/bt2/test_stream_class.py \
45 bindings/python/bt2/test_stream.py \
46 bindings/python/bt2/test_trace_collection_message_iterator.py \
47 bindings/python/bt2/test_trace.py \
48 bindings/python/bt2/test_value.py \
49 bindings/python/bt2/utils.py \
50 cli/convert/test-auto-source-discovery-grouping.sh \
51 cli/convert/test-auto-source-discovery-params.sh \
52 cli/convert/test-auto-source-discovery-log-level.sh \
53 cli/convert/test-convert-args.sh \
54 cli/list-plugins/test-list-plugins.sh \
55 cli/params/test-params.sh \
56 cli/query/test-query.sh \
57 cli/test-exit-status.sh \
58 cli/test-help.sh \
59 cli/test-intersection.sh \
60 cli/test-output-ctf-metadata.sh \
61 cli/test-output-path-ctf-non-lttng-trace.sh \
62 cli/test-packet-seq-num.sh \
63 cli/test-trace-copy.sh \
64 cli/test-trace-read.sh \
65 cli/test-trimmer.sh \
66 plugins/sink.text.details/succeed/test-succeed.sh \
67 plugins/sink.text.pretty/test-enum.sh \
68 plugins/sink.text.pretty/test_pretty.py \
69 plugins/sink.text.pretty/test-pretty-python.sh \
70 plugins/src.ctf.lttng-live/test-live.sh \
71 python-plugin-provider/bt_plugin_test_python_plugin_provider.py \
72 python-plugin-provider/test-python-plugin-provider.sh \
73 python-plugin-provider/test_python_plugin_provider.py
74
75 noinst_PROGRAMS =
76
77 TESTS_BINDINGS =
78
79 if ENABLE_PYTHON_BINDINGS
80 TESTS_BINDINGS += bindings/python/bt2/test-python-bt2.sh
81 endif
82
83 TESTS_CLI = \
84 cli/convert/test-convert-args.sh \
85 cli/test-help.sh \
86 cli/test-intersection.sh \
87 cli/test-output-ctf-metadata.sh \
88 cli/test-output-path-ctf-non-lttng-trace.sh \
89 cli/test-packet-seq-num.sh \
90 cli/test-trace-copy.sh \
91 cli/test-trace-read.sh \
92 cli/test-trimmer.sh
93
94 noinst_PROGRAMS += \
95 cpp-common/test-c-string-view
96
97 cpp_common_test_c_string_view_SOURCES = \
98 cpp-common/test-c-string-view.cpp
99
100 cpp_common_test_c_string_view_LDADD = \
101 $(COMMON_TEST_LDADD)
102
103 TESTS_CPP_COMMON = \
104 cpp-common/test-c-string-view
105
106 TESTS_LIB = \
107 lib/test-bt-uuid \
108 lib/test-bt-values \
109 lib/test-fields.sh \
110 lib/test-graph-topo \
111 lib/test-remove-destruction-listener-in-destruction-listener \
112 lib/test-simple-sink \
113 lib/test-trace-ir-ref
114
115 TESTS_BITFIELD = \
116 bitfield/test-bitfield
117
118 TESTS_CTF_WRITER = \
119 ctf-writer/test-ctf-writer.sh
120
121 if !ENABLE_BUILT_IN_PLUGINS
122 TESTS_LIB += lib/test-plugins.sh
123 endif
124
125 # plugins/flt.utils.muxer
126
127 noinst_PROGRAMS += plugins/flt.utils.muxer/test-clock-compatibility
128
129 plugins_flt_utils_muxer_test_clock_compatibility_SOURCES = \
130 plugins/flt.utils.muxer/test-clock-compatibility.cpp
131
132 plugins_flt_utils_muxer_test_clock_compatibility_LDADD = \
133 $(COMMON_TEST_LDADD) \
134 $(top_builddir)/src/lib/libbabeltrace2.la \
135 $(top_builddir)/src/cpp-common/vendor/fmt/libfmt.la
136
137 dist_check_SCRIPTS += plugins/flt.utils.muxer/test-clock-compatibility.sh
138
139 if ENABLE_BUILT_IN_PLUGINS
140 plugins_flt_utils_muxer_test_clock_compatibility_LDFLAGS = $(call pluginarchive,utils)
141 plugins_flt_utils_muxer_test_clock_compatibility_LDADD += \
142 $(top_builddir)/src/plugins/common/param-validation/libparam-validation.la
143 endif # ENABLE_BUILT_IN_PLUGINS
144
145 TESTS_PLUGINS = \
146 plugins/src.ctf.fs/fail/test-fail.sh \
147 plugins/src.ctf.fs/succeed/test-succeed.sh \
148 plugins/src.ctf.fs/test-deterministic-ordering.sh \
149 plugins/sink.ctf.fs/succeed/test-succeed.sh \
150 plugins/sink.text.details/succeed/test-succeed.sh \
151 plugins/flt.utils.muxer/test-clock-compatibility.sh
152
153 if !ENABLE_BUILT_IN_PLUGINS
154 if ENABLE_PYTHON_BINDINGS
155 TESTS_PLUGINS += plugins/src.ctf.fs/query/test-query-support-info.sh
156 TESTS_PLUGINS += plugins/src.ctf.fs/query/test-query-trace-info.sh
157 TESTS_PLUGINS += plugins/src.ctf.fs/query/test-query-metadata-info.sh
158 TESTS_PLUGINS += plugins/sink.ctf.fs/test-assume-single-trace.sh
159 TESTS_PLUGINS += plugins/sink.ctf.fs/test-stream-names.sh
160 endif
161 endif
162
163 if ENABLE_DEBUG_INFO
164 TESTS_PLUGINS += \
165 plugins/flt.lttng-utils.debug-info/test-dwarf-i386-linux-gnu.sh \
166 plugins/flt.lttng-utils.debug-info/test-dwarf-powerpc-linux-gnu.sh \
167 plugins/flt.lttng-utils.debug-info/test-dwarf-powerpc64le-linux-gnu.sh \
168 plugins/flt.lttng-utils.debug-info/test-dwarf-x86-64-linux-gnu.sh \
169 plugins/flt.lttng-utils.debug-info/test-bin-info-i386-linux-gnu.sh \
170 plugins/flt.lttng-utils.debug-info/test-bin-info-powerpc-linux-gnu.sh \
171 plugins/flt.lttng-utils.debug-info/test-bin-info-powerpc64le-linux-gnu.sh \
172 plugins/flt.lttng-utils.debug-info/test-bin-info-x86-64-linux-gnu.sh
173 endif
174
175 if ENABLE_PYTHON_PLUGINS
176 if ENABLE_PYTHON_BINDINGS
177 TESTS_CLI += \
178 cli/convert/test-auto-source-discovery-grouping.sh \
179 cli/convert/test-auto-source-discovery-log-level.sh \
180 cli/convert/test-auto-source-discovery-params.sh \
181 cli/list-plugins/test-list-plugins.sh \
182 cli/params/test-params.sh \
183 cli/query/test-query.sh \
184 cli/test-exit-status.sh
185
186 TESTS_PLUGINS += plugins/flt.utils.trimmer/test-trimming.sh \
187 plugins/flt.utils.muxer/succeed/test-succeed.sh \
188 plugins/sink.text.pretty/test-enum.sh \
189 plugins/src.ctf.fs/field/test-field.sh
190 endif
191 endif
192
193 if HAVE_PYTHON
194 TESTS_PLUGINS += plugins/src.ctf.lttng-live/test-live.sh
195
196 if DEV_MODE
197 TESTS_LIB += lib/conds/test-conds.sh
198 endif
199 endif
200
201 TESTS_PYTHON_PLUGIN_PROVIDER =
202
203 if ENABLE_PYTHON_PLUGINS
204 TESTS_PYTHON_PLUGIN_PROVIDER += python-plugin-provider/test-python-plugin-provider.sh
205 TESTS_PLUGINS += plugins/sink.text.pretty/test-pretty-python.sh
206 if ENABLE_DEBUG_INFO
207 TESTS_PLUGINS += \
208 plugins/flt.lttng-utils.debug-info/test-succeed.sh
209 endif
210 endif
211
212 TESTS_PARAM_VALIDATION = \
213 param-validation/test-param-validation
214
215 LOG_DRIVER_FLAGS = --merge --comments
216 LOG_DRIVER = env AM_TAP_AWK='$(AWK)' \
217 BT_TESTS_SRCDIR='$(abs_top_srcdir)/tests' \
218 BT_TESTS_BUILDDIR='$(abs_top_builddir)/tests' \
219 $(SHELL) $(srcdir)/utils/tap-driver.sh
220
221 TESTS_NO_BITFIELD = \
222 $(TESTS_BINDINGS) \
223 $(TESTS_CLI) \
224 $(TESTS_CPP_COMMON) \
225 $(TESTS_CTF_WRITER) \
226 $(TESTS_LIB) \
227 $(TESTS_PARAM_VALIDATION) \
228 $(TESTS_PLUGINS) \
229 $(TESTS_PYTHON_PLUGIN_PROVIDER)
230
231 TESTS = $(TESTS_NO_BITFIELD) $(TESTS_BITFIELD)
232
233 define check_target
234 check-$(1):
235 $(MAKE) $(AM_MAKEFLAGS) TESTS="$2" check
236 endef
237
238 $(eval $(call check_target,bindings,$(TESTS_BINDINGS)))
239 $(eval $(call check_target,bitfield,$(TESTS_BITFIELD)))
240 $(eval $(call check_target,cli,$(TESTS_CLI)))
241 $(eval $(call check_target,cpp-common,$(TESTS_CPP_COMMON)))
242 $(eval $(call check_target,ctf-writer,$(TESTS_CTF_WRITER)))
243 $(eval $(call check_target,lib,$(TESTS_LIB)))
244 $(eval $(call check_target,plugins,$(TESTS_PLUGINS)))
245 $(eval $(call check_target,python-plugin-provider,$(TESTS_PYTHON_PLUGIN_PROVIDER)))
246
247 check-no-bitfield:
248 $(MAKE) $(AM_MAKEFLAGS) TESTS="$(TESTS_NO_BITFIELD)" check
This page took 0.035083 seconds and 5 git commands to generate.