leaving slash in place is simple when you change nothing

This commit is contained in:
Willem van den Ende
2023-01-12 22:01:36 +00:00
parent 811b5ae848
commit 91d17742ff
+9 -1
View File
@@ -319,7 +319,6 @@ the description. This may destroy existing links, or change their targets so use
"![alt-text goes here](prefix/image.png)")))
(ert "markdown.*")
(defun qwan-echo (new-name)
(interactive "SRename function to:")
(message "Will rename to %s" new-name)
@@ -358,3 +357,12 @@ the description. This may destroy existing links, or change their targets so use
(insert (s-dashed-words new-name))
(message "Renamed %s to %s." old-name new-name)))
(message "No symbol under cursor."))))
(defun as-function-name (candidate-name)
candidate-name)
(ert-deftest refactor-rename-should-leave-forward-slash()
(should (equal (as-function-name "qwan/echo")
"qwan/echo")))
(ert "refactor.*")