]> git.notmuchmail.org Git - notmuch/commitdiff
test: add known broken test for regexp search of second subject
authorDavid Bremner <david@tethera.net>
Thu, 14 Dec 2017 14:32:34 +0000 (10:32 -0400)
committerDavid Bremner <david@tethera.net>
Thu, 3 May 2018 10:44:49 +0000 (07:44 -0300)
We expect this to give the same answer as the non-regexp subject
search. It does not because the regexp search relies on the value
slot, which currently contains only one subject.

test/T670-duplicate-mid.sh

index c198c506378ca077d75d0213008a373dc5826464..bf8cc3a816b65e8cc858411979fcd22340ac2e2d 100755 (executable)
@@ -47,6 +47,16 @@ EOF
 notmuch search --output=files subject:'"message 2"' | notmuch_dir_sanitize > OUTPUT
 test_expect_equal_file EXPECTED OUTPUT
 
+test_begin_subtest 'Regexp search for second subject'
+test_subtest_known_broken
+cat <<EOF >EXPECTED
+MAIL_DIR/copy0
+MAIL_DIR/copy1
+MAIL_DIR/copy2
+EOF
+notmuch search --output=files 'subject:"/message 2/"' | notmuch_dir_sanitize > OUTPUT
+test_expect_equal_file EXPECTED OUTPUT
+
 add_message '[id]="duplicate"' '[body]="sekrit" [filename]=copy3'
 test_begin_subtest 'search for body in duplicate file'
 cat <<EOF >EXPECTED