summaryrefslogtreecommitdiff
path: root/test/lisp/emacs-lisp/testcover-resources/testcases.el
diff options
context:
space:
mode:
authorGemini Lasswell <gazally@runbox.com>2017-07-20 12:01:42 -0700
committerNoam Postavsky <npostavs@gmail.com>2017-08-07 18:54:48 -0400
commit00f7e31110a27e568529192d7441d9631b9096bc (patch)
tree041420e82d74c21112a38ff2352e262ea019aa24 /test/lisp/emacs-lisp/testcover-resources/testcases.el
parent0508045ed7159bce5b5ea3b5fb72cf78b8b4ee8e (diff)
downloademacs-00f7e31110a27e568529192d7441d9631b9096bc.tar.gz
emacs-00f7e31110a27e568529192d7441d9631b9096bc.tar.bz2
emacs-00f7e31110a27e568529192d7441d9631b9096bc.zip
Add a test of handling of circular values to testcover-tests
* test/lisp/emacs-lisp-testcover-resources/testcases.el (testcover-testcase-cyc1): New function. (testcover-tests-circular-lists-bug-24402): New test.
Diffstat (limited to 'test/lisp/emacs-lisp/testcover-resources/testcases.el')
-rw-r--r--test/lisp/emacs-lisp/testcover-resources/testcases.el10
1 files changed, 10 insertions, 0 deletions
diff --git a/test/lisp/emacs-lisp/testcover-resources/testcases.el b/test/lisp/emacs-lisp/testcover-resources/testcases.el
index 1eb791a993c..c9a5a6daacd 100644
--- a/test/lisp/emacs-lisp/testcover-resources/testcases.el
+++ b/test/lisp/emacs-lisp/testcover-resources/testcases.el
@@ -490,4 +490,14 @@ edebug spec, so testcover needs to cope with that."
(should (eq (testcover-testcase-how-do-i-know-you "Liz") 'unknown))
+;; ==== circular-lists-bug-24402 ====
+"Testcover captures and ignores circular list errors."
+;; ====
+(defun testcover-testcase-cyc1 (a)
+ (let ((ls (make-list 10 a%%%)))
+ (nconc ls ls)
+ ls))
+(testcover-testcase-cyc1 1)
+(testcover-testcase-cyc1 1)
+
;; testcases.el ends here.