From: Nick Bowler Date: Sat, 25 Jan 2014 19:10:33 +0000 (-0500) Subject: tests: Allow custom test command wrappers X-Git-Url: http://git.draconx.ca/gitweb/liblbx.git/commitdiff_plain/0207a99806554a6ee0eeaca6faef700a97626b64 tests: Allow custom test command wrappers Add a new environment variable, TESTWRAPPER, which allows the tests to be run easily in tools like valgrind or qemu. --- diff --git a/tests/util/test-init.sh b/tests/util/test-init.sh index 2c72bf3..1754f6a 100644 --- a/tests/util/test-init.sh +++ b/tests/util/test-init.sh @@ -172,9 +172,6 @@ dx_check_pam_md5() { : "${LBXTOOL=$builddir/lbxtool$EXEEXT}" : "${LBXIMG=$builddir/lbximg$EXEEXT}" -# Set MALLOC_CHECK_ in the environment of the test programs which will enable -# malloc instrumentation on glibc-based systems to hopefully catch some forms -# of memory corruption. -dx_test_wrapper="$builddir/libtool --mode=execute env MALLOC_CHECK_=3" +dx_test_wrapper="$builddir/libtool --mode=execute${TESTWRAPPER:+ }$TESTWRAPPER" LBXTOOL="$dx_test_wrapper $LBXTOOL" LBXIMG="$dx_test_wrapper $LBXIMG"