|[ < ]||[ > ]||[ << ]||[ Up ]||[ >> ]||[Top]||[Contents]||[Index]||[ ? ]|
For putting Autotest into movement, you need some configuration and Makefile machinery. We recommend, at least if your package uses deep or shallow hierarchies, that you use `tests/' as the name of the directory holding all your tests and their `Makefile'. Here is a check list of things to do.
VERSION. This is already guaranteed if you are using Automake through the
AM_INIT_AUTOMAKEcall, but with straight Autoconf, it means that you should at least use
AC_SUBSTfor these two variables, after having initialized them to proper values.
AT_CONFIGmacro from within file `configure.ac'. This macro accepts one argument, which is the directory, relative to the test directory, where the executables are prepared.
AC_CONFIG_FILEScommand includes substitution for `tests/atconfig' and also, as appropriate, `tests/atlocal'.
With Automake, here is a minimal example about how to link `make check' with a validation suite.
EXTRA_DIST = testsuite.at testsuite TESTSUITE = $(srcdir)/testsuite check-local: atconfig atlocal $(TESTSUITE) $(SHELL) $(TESTSUITE) AUTOM4TE = autom4te AUTOTEST = $(AUTOM4TE) --language=autotest $(TESTSUITE): $(srcdir)/testsuite.at $(AUTOTEST) -I $(srcdir) $.at -o $.tmp mv $.tmp $
You might want to list explicitly the dependencies, i.e., the list of the files `testsuite.at' includes.
With strict Autoconf, you might need to add lines inspired from the following:
subdir = tests atconfig: $(top_builddir)/config.status cd $(top_builddir) && \ $(SHELL) ./config.status $(subdir)/$ atlocal: $(srcdir)/atlocal.in $(top_builddir)/config.status cd $(top_builddir) && \ $(SHELL) ./config.status $(subdir)/$
and manage to have `atconfig.in' and