X-Git-Url: https://git.notmuchmail.org/git?a=blobdiff_plain;f=test%2FT568-lib-thread.sh;fp=test%2FT568-lib-thread.sh;h=0f9fa4439235123f54f1548bf722bfe275c28c65;hb=c5017c76d939610860a64906be77fe62a64eae96;hp=c7d4f26bb84f705d8829b59f8c3906131fe9d530;hpb=70b30066f67ea75d405c8a246bf6ed923e2bdd59;p=notmuch diff --git a/test/T568-lib-thread.sh b/test/T568-lib-thread.sh index c7d4f26b..0f9fa443 100755 --- a/test/T568-lib-thread.sh +++ b/test/T568-lib-thread.sh @@ -198,4 +198,37 @@ yunaayketfm.fsf@aiko.keithp.com EOF test_expect_equal_file EXPECTED OUTPUT +test_begin_subtest "get authors from closed database" +cat c_head - c_tail <<'EOF' | test_C ${MAIL_DIR} + { + const char *authors; + authors = notmuch_thread_get_authors (thread); + printf("%d\n%s\n", thread != NULL, authors); + } +EOF +cat < EXPECTED +== stdout == +1 +Lars Kellogg-Stedman, Mikhail Gusarov, Keith Packard, Carl Worth +== stderr == +EOF +test_expect_equal_file EXPECTED OUTPUT + +test_begin_subtest "get subject from closed database" +cat c_head - c_tail <<'EOF' | test_C ${MAIL_DIR} + { + const char *subject; + subject = notmuch_thread_get_subject (thread); + printf("%d\n%s\n", thread != NULL, subject); + } +EOF +cat < EXPECTED +== stdout == +1 +[notmuch] Working with Maildir storage? +== stderr == +EOF +test_expect_equal_file EXPECTED OUTPUT + + test_done