summaryrefslogtreecommitdiff
path: root/test/lisp/emacs-lisp
diff options
context:
space:
mode:
authorLars Ingebrigtsen <larsi@gnus.org>2021-12-02 10:19:10 +0100
committerLars Ingebrigtsen <larsi@gnus.org>2021-12-02 10:19:10 +0100
commit7ca865dc52a31374c68dc870246353db5acc023c (patch)
tree2e406ece9e4e026dcf8f95e26fe49385950eddbd /test/lisp/emacs-lisp
parent5db380abad0482ae74aa71761f0da2b2351ce97a (diff)
downloademacs-7ca865dc52a31374c68dc870246353db5acc023c.tar.gz
emacs-7ca865dc52a31374c68dc870246353db5acc023c.tar.bz2
emacs-7ca865dc52a31374c68dc870246353db5acc023c.zip
Add `cl-constantly' function
* lisp/emacs-lisp/cl-lib.el (cl-constantly): Add Common Lisp function missing (bug#21584).
Diffstat (limited to 'test/lisp/emacs-lisp')
-rw-r--r--test/lisp/emacs-lisp/cl-lib-tests.el5
1 files changed, 5 insertions, 0 deletions
diff --git a/test/lisp/emacs-lisp/cl-lib-tests.el b/test/lisp/emacs-lisp/cl-lib-tests.el
index 854e371b32f..a0facc81dbe 100644
--- a/test/lisp/emacs-lisp/cl-lib-tests.el
+++ b/test/lisp/emacs-lisp/cl-lib-tests.el
@@ -551,4 +551,9 @@
(should cl-old-struct-compat-mode)
(cl-old-struct-compat-mode (if saved 1 -1))))
+(ert-deftest cl-constantly ()
+ (should (equal (mapcar (cl-constantly 3) '(a b c d))
+ '(3 3 3 3))))
+
+
;;; cl-lib-tests.el ends here