X-Git-Url: https://git.cworth.org/git?p=notmuch;a=blobdiff_plain;f=test%2Ftest-lib.sh;fp=test%2Ftest-lib.sh;h=75a62214db5eb176fc7f96ca11b3ca80a1c2aa7d;hp=59b6079dd14acf6fedddc4dcd668fd147fdfb396;hb=2707c06a0fc587a68096a3ec6f054ba4f0d7e7c7;hpb=bfcf9a6c102af9232b6d2e720f919ff1c9b431f8 diff --git a/test/test-lib.sh b/test/test-lib.sh index 59b6079d..75a62214 100644 --- a/test/test-lib.sh +++ b/test/test-lib.sh @@ -872,6 +872,19 @@ test_C () { notmuch_dir_sanitize OUTPUT.stdout OUTPUT.stderr | notmuch_exception_sanitize | notmuch_debug_sanitize > OUTPUT } +test_private_C () { + local exec_file test_file + exec_file="test${test_count}" + test_file="${exec_file}.c" + echo '#include ' > ${test_file} + cat >> ${test_file} + ${TEST_CC} ${TEST_CFLAGS} -I${NOTMUCH_SRCDIR}/test -I${NOTMUCH_SRCDIR}/lib -I${NOTMUCH_SRCDIR}/util -I${NOTMUCH_SRCDIR}/compat ${NOTMUCH_GMIME_CFLAGS} -o ${exec_file} ${test_file} ${NOTMUCH_BUILDDIR}/lib/libnotmuch.a ${NOTMUCH_GMIME_LDFLAGS} ${NOTMUCH_XAPIAN_LDFLAGS} ${NOTMUCH_BUILDDIR}/util/libnotmuch_util.a ${NOTMUCH_SFSEXP_LDFLAGS} ${NOTMUCH_BUILDDIR}/parse-time-string/libparse-time-string.a -ltalloc -lstdc++ + echo "== stdout ==" > OUTPUT.stdout + echo "== stderr ==" > OUTPUT.stderr + ./${exec_file} "$@" 1>>OUTPUT.stdout 2>>OUTPUT.stderr + notmuch_dir_sanitize OUTPUT.stdout OUTPUT.stderr | notmuch_exception_sanitize | notmuch_debug_sanitize > OUTPUT +} + make_shim () { local base_name test_file shim_file base_name="$1"