]> git.eshelyaron.com Git - emacs.git/commitdiff
Fix shell-tests failures
authorMattias Engdegård <mattiase@acm.org>
Mon, 20 Jan 2020 14:52:27 +0000 (15:52 +0100)
committerMattias Engdegård <mattiase@acm.org>
Mon, 20 Jan 2020 14:52:27 +0000 (15:52 +0100)
* test/lisp/shell-tests.el (shell-tests-completion-before-semi):
Go back to actually testing completion before semicolon.
(shell-tests-completion-after-semi): Test completion after semicolon,
correctly (bug#39075).

test/lisp/shell-tests.el

index 7113cb941c1b3d88d12a6b46727b43ac8fee4c41..606de15c9a68fd66d69bca8fa3b919fb5a8b627d 100644 (file)
   (with-temp-buffer
     (shell-mode)
     (insert "cd ba;")
+    (forward-char -1)
     (should (equal (shell--parse-pcomplete-arguments)
-                   '(("cd" "ba" "") 1 4)))))
+                   '(("cd" "ba") 1 4)))))
+
+(ert-deftest shell-tests-completion-after-semi ()
+  (with-temp-buffer
+    (shell-mode)
+    (insert "cd ba;")
+    (should (equal (shell--parse-pcomplete-arguments)
+                   '(("cd" "ba" "") 1 4 7)))))
 
 ;;; shell-tests.el ends here