X-Git-Url: https://git.notmuchmail.org/git?p=notmuch;a=blobdiff_plain;f=test%2Fjson;h=7c81856321326b0969a5d61d3e20b23b2760e7f8;hp=7fe2a27a8d6479bfd32c0d03b1c68b23ff7bf26f;hb=c6b49ae752e642d779941a63bc65d5107e7010f1;hpb=ba9f9efc9a8ba9d6e509d4041a66e9a2d31171b1 diff --git a/test/json b/test/json index 7fe2a27a..7c818563 100755 --- 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