unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
blob a7467b84856659d783261cd4872f3bb997dc5340 882 bytes (raw)
name: test/libnotmuch-abi 	 # note: path name is non-authoritative(*)

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
 
#!/usr/bin/env bash
#
# Copyright (c) 2011 David Bremner
#

test_description='libnotmuch symbol export and hiding'

# This subtest 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-lib.sh

run_exception_test(){
    result=$(LD_LIBRARY_PATH=$TEST_DIRECTORY/../lib ./exception-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 exception-test -I$TEST_DIRECTORY/../lib $TEST_DIRECTORY/exception-test.cc -L$TEST_DIRECTORY/../lib -lnotmuch -lxapian
mkdir -p fakedb/.notmuch
test_expect_success 'running exception test' run_exception_test
test_begin_subtest 'checking output'
test_expect_equal "$result" "$output" 
test_done

debug log:

solving a7467b8 ...
found a7467b8 in https://yhetil.org/notmuch/1309348595-19503-1-git-send-email-david@tethera.net/

applying [1/1] https://yhetil.org/notmuch/1309348595-19503-1-git-send-email-david@tethera.net/
diff --git a/test/libnotmuch-abi b/test/libnotmuch-abi
new file mode 100755
index 0000000..a7467b8

1:31: trailing whitespace.
test_expect_equal "$result" "$output" 
Checking patch test/libnotmuch-abi...
Applied patch test/libnotmuch-abi cleanly.
warning: 1 line adds whitespace errors.

index at:
100755 a7467b84856659d783261cd4872f3bb997dc5340	test/libnotmuch-abi

(*) Git path names are given by the tree(s) the blob belongs to.
    Blobs themselves have no identifier aside from the hash of its contents.^

Code repositories for project(s) associated with this public inbox

	https://yhetil.org/notmuch.git/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).