BSD.REGRESS.MK(5)

NAME
bsd.regress.mk - regression test master Makefile fragment

SYNOPSIS
.include <bsd.regress.mk>

DESCRIPTION
bsd.regress.mk holds the standard routines used by the source regression tests. Some variables and targets are for its internal use only. The rest are documented here.

Since this file also includes bsd.prog.mk, all of the usual OpenBSD Makefile variables may be used to build the regression test programs.

TARGETS

depend
    Build any dependencies required to carry out the current set of regression tests.

regress
    Executes all of the regression targets defined in the Makefile.

run-regress-*
    Runs an individual regression test. If the exit status of the program indicates an error or timeout, then a failure is logged, otherwise the test is marked as a success.

VARIABLES

REGRESS_FAIL_EARLY
    If this variable is set to anything but “no”, the regress target will abort as soon as a test fails.

REGRESS_LOG
    Points to the fully-qualified path of a file to which regression results are appended. Defaults to /dev/null.

REGRESS_MAXTIME
    Maximum limit of CPU seconds to spend on the regression test. Exceeding this time will result in a failure being logged.

REGRESS_ROOT_TARGETS
    Targets for which root access is required to run the test. The SUDO variable is invoked for these targets. See also SUDO.

REGRESS_SKIP_SLOW
    If this variable is not empty, skip over all the regression tests which have been marked as being 'slow' using the REGRESS_SLOW_TARGETS variable.

REGRESS_SLOW_TARGETS
    Targets which are defined as 'slow'. All of these tests can be skipped by setting the REGRESS_SKIP_SLOW variable.

REGRESS_TARGETS
    Targets which are invoked to run the set of regression tests for this Makefile. Defaults to run-regress-${PROG}.

SUDO
    Location of the sudo command, used to switch to root for certain test targets which require it.

SEE ALSO
bsd.port.mk(5)

HISTORY
The regression system originally came from NetBSD, with many tests added by OpenBSD since. The current Makefile framework was written by Artur Grabowski and Marc Espie for OpenBSD 3.1.

BUGS AND LIMITATIONS
The build system is unable to distinguish between timeouts due to REGRESS_MAXTIME being exceeded, or a genuine failure occurring.