aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorDavid Bremner <david@tethera.net>2020-07-08 21:17:08 -0300
committerDavid Bremner <david@tethera.net>2020-07-20 08:54:42 -0300
commita0c83e1fac88588ff6564dd82fbca29c2f5c78a5 (patch)
tree3b72010d8c7419fdc348750cca4fe6f348c7255a /test
parenta2279c322e65ff26a136a2fb801a1d0670a45c69 (diff)
test: add known broken test for n_m_reindex on closed db
This is another case where the code should not call INTERNAL_ERROR.
Diffstat (limited to 'test')
-rwxr-xr-xtest/T560-lib-error.sh17
1 files changed, 17 insertions, 0 deletions
diff --git a/test/T560-lib-error.sh b/test/T560-lib-error.sh
index 4805368a..8543b5dc 100755
--- a/test/T560-lib-error.sh
+++ b/test/T560-lib-error.sh
@@ -661,4 +661,21 @@ cat <<EOF > EXPECTED
EOF
test_expect_equal_file EXPECTED OUTPUT
+test_begin_subtest "Handle reindexing message with closed db"
+test_subtest_known_broken
+cat c_head2 - c_tail <<'EOF' | test_C ${MAIL_DIR}
+ {
+ notmuch_status_t status;
+ status = notmuch_message_reindex (message, NULL);
+ printf("%d\n%d\n", message != NULL, status == NOTMUCH_STATUS_XAPIAN_EXCEPTION);
+ }
+EOF
+cat <<EOF > EXPECTED
+== stdout ==
+1
+1
+== stderr ==
+EOF
+test_expect_equal_file EXPECTED OUTPUT
+
test_done