diff options
author | Dmitry Kurochkin <dmitry.kurochkin@gmail.com> | 2011-12-21 22:18:26 +0400 |
---|---|---|
committer | David Bremner <bremner@debian.org> | 2011-12-22 06:57:46 -0400 |
commit | 9a0b61da56ede4d0ff79a064d92d8c1a16cf636b (patch) | |
tree | ec74344d454916dca4d23a80df66ebcb8722c2e3 /test/emacs | |
parent | eb8638ba2e6cbb25bab2e16cdfb8568e1af617cb (diff) |
test: add test for `notmuch-hello-refresh-hook'
Test that `notmuch-hello-refresh-hook' is called once when
`notmuch-hello' is called and twice when calling
`notmuch-hello-update' after that.
The tests are very similar to tests for `notmuch-hello-mode-hook'.
Diffstat (limited to 'test/emacs')
-rwxr-xr-x | test/emacs | 19 |
1 files changed, 19 insertions, 0 deletions
@@ -495,4 +495,23 @@ counter=$(test_emacs \ ) test_expect_equal "$counter" 1 +test_begin_subtest "notmuch-hello-refresh hook is called" +counter=$(test_emacs \ + '(let ((notmuch-hello-refresh-hook-counter 0)) + (kill-buffer "*notmuch-hello*") + (notmuch-hello) + notmuch-hello-refresh-hook-counter)' +) +test_expect_equal "$counter" 1 + +test_begin_subtest "notmuch-hello-refresh hook is called on updates" +counter=$(test_emacs \ + '(let ((notmuch-hello-refresh-hook-counter 0)) + (kill-buffer "*notmuch-hello*") + (notmuch-hello) + (notmuch-hello-update) + notmuch-hello-refresh-hook-counter)' +) +test_expect_equal "$counter" 2 + test_done |