Return-Path: X-Original-To: notmuch@notmuchmail.org Delivered-To: notmuch@notmuchmail.org Received: from localhost (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id 86ADB431FDD for ; Wed, 29 Oct 2014 13:52:25 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: -2.3 X-Spam-Level: X-Spam-Status: No, score=-2.3 tagged_above=-999 required=5 tests=[RCVD_IN_DNSWL_MED=-2.3] autolearn=disabled Received: from olra.theworths.org ([127.0.0.1]) by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id TlxWAFudSMzl for ; Wed, 29 Oct 2014 13:52:20 -0700 (PDT) Received: from IPMTW1.johnshopkins.edu (ipmtw1.johnshopkins.edu [128.220.229.140]) (using TLSv1 with cipher RC4-SHA (128/128 bits)) (No client certificate requested) by olra.theworths.org (Postfix) with ESMTPS id 52C93431FC7 for ; Wed, 29 Oct 2014 13:52:13 -0700 (PDT) X-IronPort-AV: E=Sophos;i="5.07,279,1413259200"; d="scan'208";a="15776389" Received: from guppy.hwcampus.jhu.edu (HELO localhost) ([10.161.32.234]) by IPMTW1.johnshopkins.edu with ESMTP/TLS/AES128-SHA; 29 Oct 2014 16:52:11 -0400 From: Jesse Rosenthal To: notmuch@notmuchmail.org Subject: [v2 2/3] test-lib: Add dummy subject to force empty subject Date: Wed, 29 Oct 2014 16:51:44 -0400 Message-Id: <1414615905-22554-3-git-send-email-jrosenthal@jhu.edu> X-Mailer: git-send-email 2.1.2 In-Reply-To: <1414615905-22554-1-git-send-email-jrosenthal@jhu.edu> References: <1414615905-22554-1-git-send-email-jrosenthal@jhu.edu> X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 29 Oct 2014 20:52:25 -0000 At the moment, the test-lib fills in any missing headers. This makes it impossible to test our handling of empty subjects. This will allow us to use a special dummy subject -- `@FORCE_EMPTY` -- to force the subject to remain empty. --- test/test-lib.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/test/test-lib.sh b/test/test-lib.sh index 53db9ca..6057238 100644 --- a/test/test-lib.sh +++ b/test/test-lib.sh @@ -368,6 +368,8 @@ generate_message () else template[subject]="Test message #${gen_msg_cnt}" fi + elif [ "${template[subject]}" = "@FORCE_EMPTY" ]; then + template[subject]="" fi if [ -z "${template[date]}" ]; then -- 2.1.2