Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Karsten Poeck
ansi-test
Commits
358e0366
Commit
358e0366
authored
Aug 14, 2003
by
pfdietz
Browse files
Added tests for a tricky case involving searching for NIL in association lists.
parent
7d163d59
Changes
1
Hide whitespace changes
Inline
Side-by-side
ansi-tests/assoc.lsp
View file @
358e0366
...
...
@@ -150,6 +150,26 @@
(assoc 10 '((1 a) (5 b) (8 c) (11 d) (12 e)) :test-not #'>=)
(11 d))
;;; Special case: the nil key does not match the nil pair
(deftest assoc.28
(assoc nil '((a . b) nil (c . d) (nil . e) (nil . f) nil (g . h)))
(nil . e))
(deftest assoc.29
(assoc nil '((a . b) nil (c . d) (nil . e) (nil . f) nil (g . h))
:test #'eq)
(nil . e))
(deftest assoc.30
(let () (assoc nil '((a . b) nil (c . d) (nil . e) (nil . f) nil (g . h))))
(nil . e))
(deftest assoc.31
(let () (assoc nil '((a . b) nil (c . d) (nil . e) (nil . f) nil (g . h))
:test #'eq))
(nil . e))
;;; :test & :test-not together are harmless
(defharmless assoc.test-and-test-not.1
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment