aboutsummaryrefslogtreecommitdiff
path: root/evil-tests.el
diff options
context:
space:
mode:
Diffstat (limited to 'evil-tests.el')
-rw-r--r--evil-tests.el23
1 files changed, 23 insertions, 0 deletions
diff --git a/evil-tests.el b/evil-tests.el
index f22a669..88a8aa5 100644
--- a/evil-tests.el
+++ b/evil-tests.el
@@ -3529,6 +3529,29 @@ Below some empty line"
("Gkgk")
(should (not (bolp)))))
+(ert-deftest evil-test-end-of-visual-line ()
+ "Test `evil-end-of-visual-line'."
+ :tags '(evil motion)
+ (skip-unless (and (not noninteractive) (> (window-width) 2)))
+ (evil-test-buffer
+ "alpha bravo charlie\nd[e]lta echo\nfoxtrot golf hotel india"
+ ("g$" "gj")
+ "alpha bravo charlie\ndelta echo\nfoxtrot golf hotel indi[a]"
+ ("gkgk")
+ "alpha bravo charli[e]\ndelta echo\nfoxtrot golf hotel india"
+ ("ro" "2gj")
+ "alpha bravo charlio\ndelta echo\nfoxtrot golf hotel[ ]india"))
+
+(ert-deftest evil-test-eol-anchoring-with-visual-line-movement ()
+ "Test gj and gk once the cursor is anchored at eol with $."
+ :tags '(evil motion)
+ (skip-unless (and (not noninteractive) (> (window-width) 2)))
+ (evil-test-buffer
+ "Short [l]ine\nA longer line\nThird line"
+ (visual-line-mode 1)
+ ("$gj")
+ "Short line\nA longer lin[e]\nThird line"))
+
(ert-deftest evil-test-other-commands-preserve-column ()
"Test other comamnds preserve the column, when appropriate."
:tags '(evil motion)