]> git.notmuchmail.org Git - notmuch/blobdiff - test/json
test: Add test showing notmuch corrupts a part with a CRLF pair in it
[notmuch] / test / json
index 7fe2a27a8d6479bfd32c0d03b1c68b23ff7bf26f..7c81856321326b0969a5d61d3e20b23b2760e7f8 100755 (executable)
--- a/test/json
+++ b/test/json
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/usr/bin/env bash
 test_description="--format=json output"
 . ./test-lib.sh
 
@@ -39,4 +39,8 @@ test_expect_equal "$output" "[{\"thread\": \"XXX\",
 \"subject\": \"json-search-utf8-body-sübjéct\",
 \"tags\": [\"inbox\", \"unread\"]}]"
 
+test_begin_subtest "Search returning no messages"
+output=$(notmuch search --format=json "this string had better not match any messages" | notmuch_search_sanitize)
+test_expect_equal "$output" "[]"
+
 test_done