Skip to content

Commit

Permalink
Add tests for jedi:epc-server--title
Browse files Browse the repository at this point in the history
  • Loading branch information
tkf committed Mar 7, 2013
1 parent d6936b4 commit 88cb5a1
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions test-jedi.el
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,25 @@
(should (integerp column))
(should (stringp module_path)))))


;;; EPC utils

(defun jedi-testing:epc-server--title-check (command title)
(let ((copy (mapcar #'identity command)))
(should (equal (jedi:epc-server--title command) title))
;; COMMAND must not be modified in-place.
(should (equal command copy))))

(ert-deftest jedi:epc-server--title/0 ()
(jedi-testing:epc-server--title-check
'("python" "jediepcserver.py")
"Jedi: python ..."))

(ert-deftest jedi:epc-server--title/1 ()
(jedi-testing:epc-server--title-check
'("env/bin/python3" "jedi/jediepcserver.py" "--opt")
"Jedi: python3 ... --opt"))


;;; Server pool

Expand Down

0 comments on commit 88cb5a1

Please sign in to comment.