aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorArtur Malabarba <bruce.connor.am@gmail.com>2014-11-06 11:40:59 +0000
committerArtur Malabarba <bruce.connor.am@gmail.com>2014-11-06 11:40:59 +0000
commitd09556032b645d05bcb2a0164c8bb0e6f8ebf25f (patch)
tree125f39d407084f8c63a49bc7f8d25a18d596e052 /test
parent18c5a08dfb377d13afe463f5892ee2aa575b9e66 (diff)
Fix question list tests
Diffstat (limited to 'test')
-rw-r--r--test/tests.el14
1 files changed, 11 insertions, 3 deletions
diff --git a/test/tests.el b/test/tests.el
index 9bf63fd..b8001ae 100644
--- a/test/tests.el
+++ b/test/tests.el
@@ -107,10 +107,18 @@
(lambda (&rest _) stack-test-data-questions)))
(call-interactively 'list-questions))
(goto-char (point-min))
- (should (looking-at " 1 0 Focus-hook: attenuate colours when losing focus [0-9]+d ago \\[frames\\] \\[hooks\\] \\[focus\\]"))
+ (should (equal (buffer-name) "*question-list*"))
+ (should (string-match
+ "^ 1 0 Focus-hook: attenuate colours when losing focus [ 0-9]+[ydhms] ago \\[frames\\] \\[hooks\\] \\[focus\\]"
+ (thing-at-point 'line)))
(stack-question-list-next 5)
- (should (looking-at " 0 1 Babel doesn&#39;t wrap results in verbatim [0-9]+d ago \\[org-mode\\]"))
+ (should (string-match
+ "^ 0 1 Babel doesn&#39;t wrap results in verbatim [ 0-9]+[ydhms] ago \\[org-mode\\]"
+ (thing-at-point 'line)))
(call-interactively 'stack-question-list-display-question)
(should (equal (buffer-name) "*stack-question*"))
+ (switch-to-buffer "*question-list*")
(stack-question-list-previous 4)
- (should (looking-at " 2 1 &quot;Making tag completion table&quot; Freezes/Blocks -- how to disable [0-9]+d ago \\[autocomplete\\]")))
+ (should (string-match
+ "^ 2 1 &quot;Making tag completion table&quot; Freezes/Blocks -- how to disable [ 0-9]+[ydhms] ago \\[autocomplete\\]"
+ (thing-at-point 'line))))