aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar Dmitry Kurochkin <dmitry.kurochkin@gmail.com>2012-03-09 11:34:53 +0400
committerGravatar David Bremner <bremner@debian.org>2012-04-05 07:40:12 -0300
commit1361dd37bc758c84ab32f629d04327231954c60b (patch)
treee0c82c9dfc5a6e3ad02b97c5969eb0ad78e85ade
parent818790f7b52fbab06b9536e4d90c6142cadfcd5f (diff)
emacs: fix off-by-one error in notmuch-hello column alignment
Expected results for few tests are fixed, the relevant test is unmarked broken.
-rw-r--r--emacs/notmuch-hello.el2
-rwxr-xr-xtest/emacs-hello1
-rw-r--r--test/emacs.expected-output/notmuch-hello-new-section2
-rw-r--r--test/emacs.expected-output/notmuch-hello-section-with-empty2
4 files changed, 3 insertions, 4 deletions
diff --git a/emacs/notmuch-hello.el b/emacs/notmuch-hello.el
index e9caade5..28f39f19 100644
--- a/emacs/notmuch-hello.el
+++ b/emacs/notmuch-hello.el
@@ -461,7 +461,7 @@ Such a list can be computed with `notmuch-hello-query-counts'."
;; just insert `(- widest (length name))' spaces - the
;; column separator is included in the button if
;; `(equal widest (length name)'.
- (widget-insert (make-string (max 1
+ (widget-insert (make-string (max 0
(- widest (length name)))
? )))))
(setq count (1+ count))
diff --git a/test/emacs-hello b/test/emacs-hello
index 9e5d0454..be66ba4c 100755
--- a/test/emacs-hello
+++ b/test/emacs-hello
@@ -45,7 +45,6 @@ test_emacs "(let ((notmuch-hello-sections
test_expect_equal_file OUTPUT $EXPECTED/notmuch-hello-section-counts
test_begin_subtest "Column alignment for tag/queries with long names"
-test_subtest_known_broken
tag=a-very-long-tag # length carefully calculated for 80 characters window width
notmuch tag +$tag '*'
test_emacs '(notmuch-hello)
diff --git a/test/emacs.expected-output/notmuch-hello-new-section b/test/emacs.expected-output/notmuch-hello-new-section
index c64d7128..6a339aae 100644
--- a/test/emacs.expected-output/notmuch-hello-new-section
+++ b/test/emacs.expected-output/notmuch-hello-new-section
@@ -1,4 +1,4 @@
Test: [hide]
- 52 inbox
+ 52 inbox
diff --git a/test/emacs.expected-output/notmuch-hello-section-with-empty b/test/emacs.expected-output/notmuch-hello-section-with-empty
index 8209feda..dc2568de 100644
--- a/test/emacs.expected-output/notmuch-hello-section-with-empty
+++ b/test/emacs.expected-output/notmuch-hello-section-with-empty
@@ -1,4 +1,4 @@
Test-with-empty: [hide]
- 52 inbox
+ 52 inbox