9 $(srcdir)/tests
/testsuite \
10 $(srcdir)/tests
/testsuite.patch
13 tests
/ovsdb-macros.at \
15 tests
/ofproto-macros.at
24 tests
/check-structs.at \
27 tests
/ofp-actions.at \
49 tests
/tunnel-push-pop.at \
52 tests
/ovs-vswitchd.at \
53 tests
/dpif-netdev.at \
54 tests
/ofproto-dpif.at \
56 tests
/vlan-splinters.at \
60 tests
/ovsdb-types.at \
62 tests
/ovsdb-column.at \
63 tests
/ovsdb-table.at \
65 tests
/ovsdb-schema.at \
66 tests
/ovsdb-condition.at \
67 tests
/ovsdb-mutation.at \
68 tests
/ovsdb-query.at \
69 tests
/ovsdb-transaction.at \
70 tests
/ovsdb-execution.at \
71 tests
/ovsdb-trigger.at \
73 tests
/ovsdb-server.at \
74 tests
/ovsdb-monitor.at \
77 tests
/ovs-monitor-ipsec.at \
78 tests
/ovs-xapi-sync.at \
81 tests
/interface-reconfigure.at \
86 tests
/kmod-testsuite.at \
87 tests
/kmod-macros.at \
90 TESTSUITE
= $(srcdir)/tests
/testsuite
91 TESTSUITE_PATCH
= $(srcdir)/tests
/testsuite.patch
92 KMOD_TESTSUITE
= $(srcdir)/tests
/kmod-testsuite
93 DISTCLEANFILES
+= tests
/atconfig tests
/atlocal
95 AUTOTEST_PATH
= utilities
:vswitchd
:ovsdb
:vtep
:tests
97 check-local
: tests
/atconfig tests
/atlocal
$(TESTSUITE
)
98 $(SHELL
) '$(TESTSUITE)' -C tests AUTOTEST_PATH
=$(AUTOTEST_PATH
) $(TESTSUITEFLAGS
)
100 # Python Coverage support.
101 # Requires coverage.py http://nedbatchelder.com/code/coverage/.
104 COVERAGE_FILE
='$(abs_srcdir)/.coverage'
105 check-pycov
: all tests
/atconfig tests
/atlocal
$(TESTSUITE
) clean-pycov
106 PYTHONDONTWRITEBYTECODE
=yes COVERAGE_FILE
=$(COVERAGE_FILE
) PYTHON
='$(COVERAGE) run -p' $(SHELL
) '$(TESTSUITE)' -C tests AUTOTEST_PATH
=$(AUTOTEST_PATH
) $(TESTSUITEFLAGS
)
107 @cd
$(srcdir) && $(COVERAGE
) combine
&& COVERAGE_FILE
=$(COVERAGE_FILE
) $(COVERAGE
) annotate
109 @echo
'----------------------------------------------------------------------'
110 @echo
'Annotated coverage source has the ",cover" extension.'
111 @echo
'----------------------------------------------------------------------'
113 @COVERAGE_FILE
=$(COVERAGE_FILE
) $(COVERAGE
) report
117 valgrind_wrappers
= \
118 tests
/valgrind
/ovs-appctl \
119 tests
/valgrind
/ovs-ofctl \
120 tests
/valgrind
/ovstest \
121 tests
/valgrind
/ovs-vsctl \
122 tests
/valgrind
/ovs-vswitchd \
123 tests
/valgrind
/ovsdb-client \
124 tests
/valgrind
/ovsdb-server \
125 tests
/valgrind
/ovsdb-tool \
126 tests
/valgrind
/test-aes128 \
127 tests
/valgrind
/test-atomic \
128 tests
/valgrind
/test-bundle \
129 tests
/valgrind
/test-byte-order \
130 tests
/valgrind
/test-classifier \
131 tests
/valgrind
/test-cmap \
132 tests
/valgrind
/test-csum \
133 tests
/valgrind
/test-flows \
134 tests
/valgrind
/test-hash \
135 tests
/valgrind
/test-hindex \
136 tests
/valgrind
/test-hmap \
137 tests
/valgrind
/test-json \
138 tests
/valgrind
/test-jsonrpc \
139 tests
/valgrind
/test-list \
140 tests
/valgrind
/test-lockfile \
141 tests
/valgrind
/test-multipath \
142 tests
/valgrind
/test-odp \
143 tests
/valgrind
/test-ovsdb \
144 tests
/valgrind
/test-packets \
145 tests
/valgrind
/test-random \
146 tests
/valgrind
/test-reconnect \
147 tests
/valgrind
/test-rstp \
148 tests
/valgrind
/test-sha1 \
149 tests
/valgrind
/test-stp \
150 tests
/valgrind
/test-type-props \
151 tests
/valgrind
/test-unix-socket \
152 tests
/valgrind
/test-uuid \
153 tests
/valgrind
/test-vconn
155 $(valgrind_wrappers
): tests
/valgrind-wrapper.in
156 @
test -d tests
/valgrind || mkdir tests
/valgrind
157 $(AM_V_GEN
) sed
-e
's,[@]wrap_program[@],$@,' \
158 $(top_srcdir
)/tests
/valgrind-wrapper.in
> $@.tmp
&& \
161 CLEANFILES
+= $(valgrind_wrappers
)
162 EXTRA_DIST
+= tests
/valgrind-wrapper.in
164 VALGRIND
= valgrind
--log-file
=valgrind.
%p
--leak-check
=full \
165 --suppressions
=$(abs_top_srcdir
)/tests
/glibc.supp \
166 --suppressions
=$(abs_top_srcdir
)/tests
/openssl.supp
--num-callers
=20
167 EXTRA_DIST
+= tests
/glibc.supp tests
/openssl.supp
168 check-valgrind
: all tests
/atconfig tests
/atlocal
$(TESTSUITE
) \
169 $(valgrind_wrappers
) $(check_DATA
)
170 $(SHELL
) '$(TESTSUITE)' -C tests CHECK_VALGRIND
=true VALGRIND
='$(VALGRIND)' AUTOTEST_PATH
='tests/valgrind:$(AUTOTEST_PATH)' -d
$(TESTSUITEFLAGS
)
172 @echo
'----------------------------------------------------------------------'
173 @echo
'Valgrind output can be found in tests/testsuite.dir/*/valgrind.*'
174 @echo
'----------------------------------------------------------------------'
179 $(AM_V_at
)srcdir='$(srcdir)' $(SHELL
) $(srcdir)/tests
/run-oftest
180 EXTRA_DIST
+= tests
/run-oftest
184 $(AM_V_at
)srcdir='$(srcdir)' $(SHELL
) $(srcdir)/tests
/run-ryu
185 EXTRA_DIST
+= tests
/run-ryu
187 # Run kmod tests. Assume kernel modules has been installed or linked into the kernel
188 check-kernel
: all tests
/atconfig tests
/atlocal
$(KMOD_TESTSUITE
)
189 $(SHELL
) '$(KMOD_TESTSUITE)' -C tests AUTOTEST_PATH
='$(AUTOTEST_PATH)' -d
$(TESTSUITEFLAGS
)
191 # Testing the out of tree Kernel module
192 check-kmod
: all tests
/atconfig tests
/atlocal
$(KMOD_TESTSUITE
)
193 $(MAKE
) modules_install
194 modprobe
-r openvswitch
198 test ! -f
'$(TESTSUITE)' ||
$(SHELL
) '$(TESTSUITE)' -C tests
--clean
200 AUTOTEST
= $(AUTOM4TE
) --language
=autotest
201 $(TESTSUITE
): package.m4
$(TESTSUITE_AT
) $(COMMON_MACROS_AT
) $(TESTSUITE_PATCH
)
202 $(AM_V_GEN
)$(AUTOTEST
) -I
'$(srcdir)' -o
$@.tmp
$@.at
203 patch
-p0
$@.tmp
$(TESTSUITE_PATCH
)
204 $(AM_V_at
)mv
$@.tmp
$@
206 $(KMOD_TESTSUITE
): package.m4
$(KMOD_TESTSUITE_AT
) $(COMMON_MACROS_AT
)
207 $(AM_V_GEN
)$(AUTOTEST
) -I
'$(srcdir)' -o
$@.tmp
$@.at
208 $(AM_V_at
)mv
$@.tmp
$@
210 # The `:;' works around a Bash 3.2 bug when the output is not writeable.
211 $(srcdir)/package.m4
: $(top_srcdir
)/configure.ac
213 echo
'# Signature of the current package.' && \
214 echo
'm4_define([AT_PACKAGE_NAME], [$(PACKAGE_NAME)])' && \
215 echo
'm4_define([AT_PACKAGE_TARNAME], [$(PACKAGE_TARNAME)])' && \
216 echo
'm4_define([AT_PACKAGE_VERSION], [$(PACKAGE_VERSION)])' && \
217 echo
'm4_define([AT_PACKAGE_STRING], [$(PACKAGE_STRING)])' && \
218 echo
'm4_define([AT_PACKAGE_BUGREPORT], [$(PACKAGE_BUGREPORT)])'; \
219 } >'$(srcdir)/package.m4'
221 noinst_PROGRAMS
+= tests
/test-ovsdb
222 tests_test_ovsdb_SOURCES
= \
226 EXTRA_DIST
+= tests
/uuidfilt.pl tests
/ovsdb-monitor-sort.pl
227 tests_test_ovsdb_LDADD
= ovsdb
/libovsdb.la lib
/libopenvswitch.la
229 noinst_PROGRAMS
+= tests
/test-lib
230 tests_test_lib_SOURCES
= \
232 tests_test_lib_LDADD
= lib
/libopenvswitch.la
234 # idltest schema and IDL
235 OVSIDL_BUILT
+= tests
/idltest.c tests
/idltest.h tests
/idltest.ovsidl
236 IDLTEST_IDL_FILES
= tests
/idltest.ovsschema tests
/idltest.ann
237 EXTRA_DIST
+= $(IDLTEST_IDL_FILES
)
238 tests
/idltest.ovsidl
: $(IDLTEST_IDL_FILES
)
239 $(AM_V_GEN
)$(OVSDB_IDLC
) -C
$(srcdir) annotate
$(IDLTEST_IDL_FILES
) > $@.tmp
&& \
242 tests
/idltest.c
: tests
/idltest.h
245 noinst_PROGRAMS
+= tests
/test-dpdkr
246 tests_test_dpdkr_SOURCES
= \
247 tests
/dpdk
/ring_client.c
248 tests_test_dpdkr_LDADD
= lib
/libopenvswitch.la
$(LIBS
)
251 noinst_PROGRAMS
+= tests
/ovstest
252 tests_ovstest_SOURCES
= \
255 tests
/test-aes128.c \
256 tests
/test-atomic.c \
257 tests
/test-bundle.c \
258 tests
/test-byte-order.c \
259 tests
/test-classifier.c \
265 tests
/test-hindex.c \
268 tests
/test-jsonrpc.c \
270 tests
/test-lockfile.c \
271 tests
/test-multipath.c \
272 tests
/test-netflow.c \
274 tests
/test-packets.c \
275 tests
/test-random.c \
276 tests
/test-reconnect.c \
283 tests
/test-bitmap.c \
287 tests_ovstest_SOURCES
+= \
288 tests
/test-unix-socket.c
291 tests_ovstest_LDADD
= lib
/libopenvswitch.la
292 dist_check_SCRIPTS
= tests
/flowgen.pl
294 noinst_PROGRAMS
+= tests
/test-strtok_r
295 tests_test_strtok_r_SOURCES
= tests
/test-strtok_r.c
297 noinst_PROGRAMS
+= tests
/test-type-props
298 tests_test_type_props_SOURCES
= tests
/test-type-props.c
303 tests
/test-daemon.py \
305 tests
/test-jsonrpc.py \
306 tests
/test-ovsdb.py \
307 tests
/test-reconnect.py \
308 tests
/MockXenAPI.py \
309 tests
/test-unix-socket.py \
310 tests
/test-unixctl.py \
312 EXTRA_DIST
+= $(CHECK_PYFILES
)
313 PYCOV_CLEAN_FILES
+= $(CHECK_PYFILES
:.py
=.py
,cover
) .coverage
317 tests
/testpki-cacert.pem \
318 tests
/testpki-cert.pem \
319 tests
/testpki-privkey.pem \
320 tests
/testpki-req.pem \
321 tests
/testpki-cert2.pem \
322 tests
/testpki-privkey2.pem \
323 tests
/testpki-req2.pem
324 check_DATA
+= $(TESTPKI_FILES
)
325 CLEANFILES
+= $(TESTPKI_FILES
)
327 tests
/testpki-cacert.pem
: tests
/pki
/stamp
328 $(AM_V_GEN
)cp tests
/pki
/switchca
/cacert.pem
$@
329 tests
/testpki-cert.pem
: tests
/pki
/stamp
330 $(AM_V_GEN
)cp tests
/pki
/test-cert.pem
$@
331 tests
/testpki-req.pem
: tests
/pki
/stamp
332 $(AM_V_GEN
)cp tests
/pki
/test-req.pem
$@
333 tests
/testpki-privkey.pem
: tests
/pki
/stamp
334 $(AM_V_GEN
)cp tests
/pki
/test-privkey.pem
$@
335 tests
/testpki-cert2.pem
: tests
/pki
/stamp
336 $(AM_V_GEN
)cp tests
/pki
/test2-cert.pem
$@
337 tests
/testpki-req2.pem
: tests
/pki
/stamp
338 $(AM_V_GEN
)cp tests
/pki
/test2-req.pem
$@
339 tests
/testpki-privkey2.pem
: tests
/pki
/stamp
340 $(AM_V_GEN
)cp tests
/pki
/test2-privkey.pem
$@
342 OVS_PKI
= $(SHELL
) $(srcdir)/utilities
/ovs-pki.in
--dir=tests
/pki
--log
=tests
/ovs-pki.log
344 $(AM_V_at
)rm -f tests
/pki
/stamp
345 $(AM_V_at
)rm -rf tests
/pki
346 $(AM_V_GEN
)$(OVS_PKI
) init
&& \
347 $(OVS_PKI
) req
+sign tests
/pki
/test && \
348 $(OVS_PKI
) req
+sign tests
/pki
/test2
&& \
350 CLEANFILES
+= tests
/ovs-pki.log
352 CLEAN_LOCAL
+= clean-pki
354 rm -f tests
/pki
/stamp