1
0
mirror of synced 2026-05-05 23:54:46 +00:00
Files
Interlisp.medley/internal/test/LANGUAGE/AUTO/6-3-EQL.TEST

57 lines
1005 B
Plaintext

;; Function To Be Tested: EQL
;;
;; Source: Guy L Steele's CLTL
;; Section: 6.3 Equality Predicates
;; Page: 78
;;
;; Created By: John Sybalsky
;;
;; Creation Date: July 30,1986
;;
;; Last Update: 16 12 86 Peter Reidy - added do-test-group
;;
;; Filed As: {ERIS}<LISPCORE>CML>TEST>6-3-eql.TEST
;;
;;
;; Syntax: (eq x y)
;;
;; Function Description:
;;
(do-test-group eql-test
(do-test "EQL on symbols"
(and (not (eql 'a 'b))
(eql 'a 'a)))
(do-test EQL-on-CONSes
(not (eql (cons 'a 'b) (cons 'a 'b))))
(do-test EQL-on-the-same-CONS
(let ((x (cons 3 4.5))) (eql x x)))
(do-test EQL-on-smallps
(and (eql 0 0)
(eql 65534 65534)
(eql -32700 -32700)
(not (eql 0 1))
)
)
(do-test EQL-on-complex
(and (eql #c(3 4) #c(3 4))
(eql #c(3 4.1) #c(3 4.1))
(not (eql #c(3 4) #c(3.0 4.0)))
)
)
(do-test EQL-on-strings
(and (not (eql "Foo" "foo"))
(let ((x "foo")) (eql x x) )
)
)
)
STOP