source: trunk/tests/ansi-tests/hash-table-rehash-threshold.lsp @ 12072

Last change on this file since 12072 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: 1.1 KB
Line 
1;-*- Mode:     Lisp -*-
2;;;; Author:   Paul Dietz
3;;;; Created:  Fri Nov 28 05:52:52 2003
4;;;; Contains: Tests of HASH-TABLE-REHASH-THRESHOLD
5
6(in-package :cl-test)
7
8(deftest hash-table-rehash-threshold.1
9  (typep* (hash-table-rehash-threshold (make-hash-table))
10          '(real 0 1))
11  t)
12
13(deftest hash-table-rehash-threshold.2
14  (loop for test in '(eq eql equal equalp)
15        unless (typep* (hash-table-rehash-threshold (make-hash-table :test test))
16                       '(real 0 1))
17        collect test)
18  nil)
19
20(deftest hash-table-rehash-threshold.3
21  (loop for test in '(eq eql equal equalp)
22        for fn = (symbol-function test)
23        unless (typep* (hash-table-rehash-threshold (make-hash-table :test fn))
24                       '(real 0 1))
25        collect test)
26  nil)
27
28(deftest hash-table-rehash-threshold.error.1
29  (signals-error (hash-table-rehash-threshold) program-error)
30  t)
31
32(deftest hash-table-rehash-threshold.error.2
33  (signals-error (hash-table-rehash-threshold (make-hash-table) nil)
34                 program-error)
35  t)
36
37(deftest hash-table-rehash-threshold.error.3
38  (check-type-error #'hash-table-rehash-threshold #'hash-table-p)
39  nil)
Note: See TracBrowser for help on using the repository browser.