mirror of
https://git.notmuchmail.org/git/notmuch
synced 2024-11-28 21:54:10 +01:00
eb4cf465a5
Change add_email_corpus, emacs_deliver_message and tests to use $TEST_DIRECTORY instead of '..'. This improves the behavior of the usage of --root=<dir>, as the assumption of what '..' means will usually be incorrect. Document -root option in README and update valgrind to work with -root.
26 lines
828 B
Bash
Executable file
26 lines
828 B
Bash
Executable file
#!/usr/bin/env bash
|
|
#
|
|
# Copyright (c) 2011 David Bremner
|
|
#
|
|
|
|
# This test tests whether hiding Xapian::Error symbols in libnotmuch
|
|
# also hides them for other users of libxapian. This is motivated by
|
|
# the discussion in http://gcc.gnu.org/wiki/Visibility'
|
|
|
|
test_description='exception symbol hiding'
|
|
|
|
. ./test-lib.sh
|
|
|
|
run_test(){
|
|
result=$(LD_LIBRARY_PATH=$TEST_DIRECTORY/../lib ./symbol-test 2>&1)
|
|
}
|
|
|
|
output="A Xapian exception occurred opening database: Couldn't stat 'fakedb/.notmuch/xapian'
|
|
caught No chert database found at path \`./nonexistant'"
|
|
|
|
g++ -o symbol-test -I$TEST_DIRECTORY/../lib $TEST_DIRECTORY/symbol-test.cc -L$TEST_DIRECTORY/../lib -lnotmuch -lxapian
|
|
mkdir -p fakedb/.notmuch
|
|
test_expect_success 'running test' run_test
|
|
test_begin_subtest 'checking output'
|
|
test_expect_equal "$result" "$output"
|
|
test_done
|