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 31828431FD2 for ; Sat, 4 Feb 2012 12:44:51 -0800 (PST) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: 0.201 X-Spam-Level: X-Spam-Status: No, score=0.201 tagged_above=-999 required=5 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_ENVFROM_END_DIGIT=1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7] 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 ECbNiWiZhgk9 for ; Sat, 4 Feb 2012 12:44:49 -0800 (PST) Received: from mail-we0-f181.google.com (mail-we0-f181.google.com [74.125.82.181]) (using TLSv1 with cipher RC4-SHA (128/128 bits)) (No client certificate requested) by olra.theworths.org (Postfix) with ESMTPS id A2495431FCF for ; Sat, 4 Feb 2012 12:44:46 -0800 (PST) Received: by mail-we0-f181.google.com with SMTP id b10so4024656wer.26 for ; Sat, 04 Feb 2012 12:44:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references; bh=ZE+uezOiqrURWWYfGUToGg4+lHSBIk/arOgfD/IQagE=; b=lRMWK9nKtjw/mvFg/T6+OEfjtVr1AMxI9koAid/KJQiVLjBIEkCJrkk1CPVyNR4Rhj Rr/md+D/BwGS8YeT2Xw4wd9IbV+VXYmoLdRXbciVNMDVvCzKmQleBIHNzgxPD+OgqiQl 43l8x8OUeZfTTL7uR6MdhSAGf0HjxVrbRlu28= Received: by 10.216.135.35 with SMTP id t35mr4841954wei.9.1328388286390; Sat, 04 Feb 2012 12:44:46 -0800 (PST) Received: from localhost (94-192-233-223.zone6.bethere.co.uk. [94.192.233.223]) by mx.google.com with ESMTPS id dw7sm14965290wib.4.2012.02.04.12.44.45 (version=TLSv1/SSLv3 cipher=OTHER); Sat, 04 Feb 2012 12:44:45 -0800 (PST) From: Mark Walters To: notmuch@notmuchmail.org Subject: [PATCH v2 4/4] test: test the new --from option to notmuch-reply Date: Sat, 4 Feb 2012 20:45:17 +0000 Message-Id: <1328388317-20161-5-git-send-email-markwalters1009@gmail.com> X-Mailer: git-send-email 1.7.2.3 In-Reply-To: <1328388317-20161-1-git-send-email-markwalters1009@gmail.com> References: <1328388317-20161-1-git-send-email-markwalters1009@gmail.com> 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: Sat, 04 Feb 2012 20:44:51 -0000 --- test/reply | 69 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 files changed, 69 insertions(+), 0 deletions(-) diff --git a/test/reply b/test/reply index 00f4bea..0bb22bb 100755 --- a/test/reply +++ b/test/reply @@ -138,4 +138,73 @@ References: <${gen_msg_id}> On Tue, 05 Jan 2010 15:43:56 -0000, Notmuch Test Suite wrote: > 200-byte header" + +test_begin_subtest "reply --from=none" +add_message '[from]="Sender "' \ + [to]=test_suite@notmuchmail.org \ + [subject]=notmuch-reply-test \ + '[date]="Tue, 05 Jan 2010 15:43:56 -0000"' \ + '[body]="reply --from=none test"' + +output=$(notmuch reply --from=none id:${gen_msg_id}) +test_expect_equal "$output" "From: +Subject: Re: notmuch-reply-test +To: Sender +In-Reply-To: <${gen_msg_id}> +References: <${gen_msg_id}> + +On Tue, 05 Jan 2010 15:43:56 -0000, Sender wrote: +> reply --from=none test" + +test_begin_subtest "reply --from:fallback-none" +add_message '[from]="Sender "' \ + '[to]="Someone Else "' \ + [subject]=notmuch-reply-test \ + '[date]="Tue, 05 Jan 2010 15:43:56 -0000"' \ + '[body]="reply --from=fallback-none test"' + +output=$(notmuch reply --from=fallback-none id:${gen_msg_id}) +test_expect_equal "$output" "From: +Subject: Re: notmuch-reply-test +To: Sender , Someone Else +In-Reply-To: <${gen_msg_id}> +References: <${gen_msg_id}> + +On Tue, 05 Jan 2010 15:43:56 -0000, Sender wrote: +> reply --from=fallback-none test" + +test_begin_subtest "reply default from:" +add_message '[from]="Sender "' \ + '[to]="Someone Else "' \ + [subject]=notmuch-reply-test \ + '[date]="Tue, 05 Jan 2010 15:43:56 -0000"' \ + '[body]="reply default from: test"' + +output=$(notmuch reply id:${gen_msg_id}) +test_expect_equal "$output" "From: Notmuch Test Suite +Subject: Re: notmuch-reply-test +To: Sender , Someone Else +In-Reply-To: <${gen_msg_id}> +References: <${gen_msg_id}> + +On Tue, 05 Jan 2010 15:43:56 -0000, Sender wrote: +> reply default from: test" + +test_begin_subtest "Reply --from=primary" +add_message '[from]="Sender "' \ + [to]=test_suite_other@notmuchmail.org \ + [subject]=notmuch-reply-test \ + '[date]="Tue, 05 Jan 2010 15:43:56 -0000"' \ + '[body]="reply --from=primary"' + +output=$(notmuch reply --from=primary id:${gen_msg_id}) +test_expect_equal "$output" "From: Notmuch Test Suite +Subject: Re: notmuch-reply-test +To: Sender +In-Reply-To: <${gen_msg_id}> +References: <${gen_msg_id}> + +On Tue, 05 Jan 2010 15:43:56 -0000, Sender wrote: +> reply --from=primary" + test_done -- 1.7.2.3