source: trunk/source/tests/ansi-tests/identity.lsp @ 8991

Last change on this file since 8991 was 8991, checked in by gz, 12 years ago

Check in the gcl ansi test suite (original, in preparation for making local changes)

File size: 674 bytes
Line 
1;-*- Mode:     Lisp -*-
2;;;; Author:   Paul Dietz
3;;;; Created:  Thu Oct 17 23:21:11 2002
4;;;; Contains: Tests for IDENTITY
5
6(in-package :cl-test)
7
8(deftest identity.1
9  (check-predicate #'(lambda (x) (eqlt x (check-values (identity x)))))
10  nil)
11
12(deftest identity.2
13  (let ((x (ash 1 100)))
14    (eqlt x (check-values (identity x))))
15  t)
16
17(deftest identity.3
18  (let ((x 1.00000001))
19    (eqlt x (check-values (identity x))))
20  t)
21
22(deftest identity.order.1
23  (let ((i 0))
24    (values (identity (incf i)) i))
25  1 1)
26
27(deftest identity.error.1
28  (signals-error (identity) program-error)
29  t)
30
31(deftest identity.error.2
32  (signals-error (identity 'a 'a) program-error)
33  t)
34
Note: See TracBrowser for help on using the repository browser.