From 0a403bfde71c4b82147473298d3a60b4171468bd Mon Sep 17 00:00:00 2001 From: Darren Tucker Date: Mon, 30 Sep 2019 14:11:42 +1000 Subject: Add SKIP_LTESTS for skipping specific tests. --- regress/Makefile | 12 ++++++++++-- regress/README.regress | 1 + 2 files changed, 11 insertions(+), 2 deletions(-) (limited to 'regress') diff --git a/regress/Makefile b/regress/Makefile index 933fbb424..34c47e8cb 100644 --- a/regress/Makefile +++ b/regress/Makefile @@ -210,8 +210,16 @@ t12: $(OBJ)/t12.out t-exec: ${LTESTS:=.sh} @if [ "x$?" = "x" ]; then exit 0; fi; \ for TEST in ""$?; do \ - echo "run test $${TEST}" ... 1>&2; \ - (env SUDO="${SUDO}" TEST_ENV=${TEST_ENV} ${TEST_SHELL} ${.CURDIR}/test-exec.sh ${.OBJDIR} ${.CURDIR}/$${TEST}) || exit $$?; \ + skip=no; \ + for t in ""$${SKIP_LTESTS}; do \ + if [ "x$${t}.sh" = "x$${TEST}" ]; then skip=yes; fi; \ + done; \ + if [ "x$${skip}" = "xno" ]; then \ + echo "run test $${TEST}" ... 1>&2; \ + (env SUDO="${SUDO}" TEST_ENV=${TEST_ENV} ${TEST_SHELL} ${.CURDIR}/test-exec.sh ${.OBJDIR} ${.CURDIR}/$${TEST}) || exit $$?; \ + else \ + echo skip test $${TEST} 1>&2; \ + fi; \ done t-exec-interop: ${INTEROP_TESTS:=.sh} diff --git a/regress/README.regress b/regress/README.regress index ed9de874c..ac2e8487e 100644 --- a/regress/README.regress +++ b/regress/README.regress @@ -25,6 +25,7 @@ SUDO: path to sudo/doas command, if desired. Note that some systems (notably systems using PAM) require sudo to execute some tests. LTESTS: Whitespace separated list of tests (filenames without the .sh extension) to run. +SKIP_LTESTS: Whitespace separated list of tests to skip. OBJ: used by test scripts to access build dir. TEST_SHELL: shell used for running the test scripts. TEST_SSH_FAIL_FATAL: set to "yes" to make any failure abort the test -- cgit v1.2.3