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 1993D429E34 for ; Sat, 17 Dec 2011 16:22:12 -0800 (PST) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: -0.799 X-Spam-Level: X-Spam-Status: No, score=-0.799 tagged_above=-999 required=5 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.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 8EEzZItJqko4 for ; Sat, 17 Dec 2011 16:22:11 -0800 (PST) Received: from mail-ww0-f41.google.com (mail-ww0-f41.google.com [74.125.82.41]) (using TLSv1 with cipher RC4-SHA (128/128 bits)) (No client certificate requested) by olra.theworths.org (Postfix) with ESMTPS id 1A2FD429E31 for ; Sat, 17 Dec 2011 16:22:08 -0800 (PST) Received: by wgbdt12 with SMTP id dt12so4921505wgb.2 for ; Sat, 17 Dec 2011 16:22:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=from:to:subject:date:message-id:x-mailer:in-reply-to:references; bh=85A3jP9We8emThvSQ9Ivoxkcg6+hII7rvC9ncICzo2k=; b=ulFT1OUe5mbQv0/71LprWEYl32CqW7UN4g6aoBO6/T13mbSKR6lAzEk/7KHmCgjuQn gjf3O7NCxTxSChKFMO1zPReZ2vhj03bPC8ALMOEEI3iBSwUrC7qp1LrgV7vmGKz5/r33 s0bb31z6pM6cnlKP1NH0LaeK5pjRZd3+mccrw= Received: by 10.180.104.2 with SMTP id ga2mr24014813wib.33.1324167727986; Sat, 17 Dec 2011 16:22:07 -0800 (PST) Received: from localhost ([91.144.186.21]) by mx.google.com with ESMTPS id n9sm20066232wbo.16.2011.12.17.16.22.06 (version=TLSv1/SSLv3 cipher=OTHER); Sat, 17 Dec 2011 16:22:07 -0800 (PST) From: Dmitry Kurochkin To: notmuch@notmuchmail.org Subject: [PATCH v4 2/4] test: add test for `notmuch-hello-mode-hook' Date: Sun, 18 Dec 2011 04:21:19 +0400 Message-Id: <1324167681-26984-3-git-send-email-dmitry.kurochkin@gmail.com> X-Mailer: git-send-email 1.7.7.3 In-Reply-To: <1324167681-26984-1-git-send-email-dmitry.kurochkin@gmail.com> References: <1324095619-10870-1-git-send-email-dmitry.kurochkin@gmail.com> <1324167681-26984-1-git-send-email-dmitry.kurochkin@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: Sun, 18 Dec 2011 00:22:12 -0000 Test that `notmuch-hello-mode-hook' is called once when `notmuch-hello' function is called. --- test/emacs | 9 +++++++++ 1 files changed, 9 insertions(+), 0 deletions(-) diff --git a/test/emacs b/test/emacs index 6e922de..a864ffa 100755 --- a/test/emacs +++ b/test/emacs @@ -476,4 +476,13 @@ test_emacs "(let ((notmuch-command \"$notmuch_counter_command\")) (notmuch-show \"id:$id\"))" test_expect_equal $(notmuch_counter_value) 1 +test_begin_subtest "notmuch-hello-mode hook is called" +counter=$(test_emacs \ + '(let ((notmuch-hello-mode-hook-counter 0)) + (kill-buffer "*notmuch-hello*") + (notmuch-hello) + notmuch-hello-mode-hook-counter)' +) +test_expect_equal "$counter" 1 + test_done -- 1.7.7.3