The test in json was inferior to the one in search-output, since it
wasn't properly testing for the presence of a trailing newline.
\"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
test_begin_subtest "notmuch search --format=json for non-existent message prints proper empty json"
notmuch search --format=json "no-message-matches-this" > OUTPUT
-cat <<EOF >EXPECTED
-[]
-EOF
+echo "[]" >EXPECTED
test_expect_equal_file OUTPUT EXPECTED
test_done