aboutsummaryrefslogtreecommitdiff
path: root/evil-tests.el
diff options
context:
space:
mode:
Diffstat (limited to 'evil-tests.el')
-rw-r--r--evil-tests.el12
1 files changed, 12 insertions, 0 deletions
diff --git a/evil-tests.el b/evil-tests.el
index 73eed9e..eb638cf 100644
--- a/evil-tests.el
+++ b/evil-tests.el
@@ -8137,6 +8137,18 @@ maybe we need one line more with some text\n")
"[l]line 1\nline 2"
(":read!echo cmd line 1" [return])
"line 1\n[c]md line 1\nline 2")))
+ (ert-info ("Test substitution of % in shell commands")
+ (evil-with-temp-file name
+ "3\n2\n1\n"
+ (evil-test-buffer
+ ((vconcat ":e " name [return]))
+ "[3]\n2\n1\n"
+ ((vconcat ":read !echo %" [return]))
+ ((vconcat ":w " [return]))
+ (file name (concat "3\n"
+ (buffer-file-name) "\n"
+ "2\n"
+ "1\n")))))
(ert-info ("Test insertion of shell command without trailing newline")
(ert-info ("with space")
(evil-test-buffer