Commit b2be6596 authored by pfdietz's avatar pfdietz

Changed classify-error forms to signals-error forms.

parent a48cda76
......@@ -6,12 +6,12 @@
(in-package :cl-test)
(deftest random-state-p.error.1
(classify-error (random-state-p))
program-error)
(signals-error (random-state-p) program-error)
t)
(deftest random-state-p.error.2
(classify-error (random-state-p nil nil))
program-error)
(signals-error (random-state-p nil nil) program-error)
t)
(deftest random-state-p.1
(loop for x in *universe*
......
......@@ -9,17 +9,17 @@
(compile-and-load "random-aux.lsp")
(deftest random.error.1
(classify-error (random))
program-error)
(signals-error (random) program-error)
t)
(deftest random.error.2
(classify-error (random 10 *random-state* nil))
program-error)
(signals-error (random 10 *random-state* nil) program-error)
t)
(deftest random.error.3
(loop for x in *mini-universe*
unless (or (and (realp x) (> x 0))
(eq (eval `(classify-error (random ',x))) 'type-error))
(eval `(signals-error (random ',x) type-error)))
collect x)
nil)
......
......@@ -97,45 +97,45 @@
;;; Error tests
(deftest rassoc-if-not.error.1
(classify-error (rassoc-if-not))
program-error)
(signals-error (rassoc-if-not) program-error)
t)
(deftest rassoc-if-not.error.2
(classify-error (rassoc-if-not #'null))
program-error)
(signals-error (rassoc-if-not #'null) program-error)
t)
(deftest rassoc-if-not.error.3
(classify-error (rassoc-if-not #'null nil :bad t))
program-error)
(signals-error (rassoc-if-not #'null nil :bad t) program-error)
t)
(deftest rassoc-if-not.error.4
(classify-error (rassoc-if-not #'null nil :key))
program-error)
(signals-error (rassoc-if-not #'null nil :key) program-error)
t)
(deftest rassoc-if-not.error.5
(classify-error (rassoc-if-not #'null nil 1 1))
program-error)
(signals-error (rassoc-if-not #'null nil 1 1) program-error)
t)
(deftest rassoc-if-not.error.6
(classify-error (rassoc-if-not #'null nil :bad t :allow-other-keys nil))
program-error)
(signals-error (rassoc-if-not #'null nil :bad t :allow-other-keys nil) program-error)
t)
(deftest rassoc-if-not.error.7
(classify-error (rassoc-if-not #'cons '((a . b)(c . d))))
program-error)
(signals-error (rassoc-if-not #'cons '((a . b)(c . d))) program-error)
t)
(deftest rassoc-if-not.error.8
(classify-error (rassoc-if-not #'car '((a . b)(c . d))))
type-error)
(signals-error (rassoc-if-not #'car '((a . b)(c . d))) type-error)
t)
(deftest rassoc-if-not.error.9
(classify-error (rassoc-if-not #'identity '((a . b)(c . d)) :key #'cons))
program-error)
(signals-error (rassoc-if-not #'identity '((a . b)(c . d)) :key #'cons) program-error)
t)
(deftest rassoc-if-not.error.10
(classify-error (rassoc-if-not #'identity '((a . b)(c . d)) :key #'car))
type-error)
(signals-error (rassoc-if-not #'identity '((a . b)(c . d)) :key #'car) type-error)
t)
(deftest rassoc-if-not.error.11
(classify-error (rassoc-if-not #'identity '((a . b) . c)))
type-error)
(signals-error (rassoc-if-not #'identity '((a . b) . c)) type-error)
t)
......@@ -92,46 +92,46 @@
;;; Error tests
(deftest rassoc-if.error.1
(classify-error (rassoc-if))
program-error)
(signals-error (rassoc-if) program-error)
t)
(deftest rassoc-if.error.2
(classify-error (rassoc-if #'null))
program-error)
(signals-error (rassoc-if #'null) program-error)
t)
(deftest rassoc-if.error.3
(classify-error (rassoc-if #'null nil :bad t))
program-error)
(signals-error (rassoc-if #'null nil :bad t) program-error)
t)
(deftest rassoc-if.error.4
(classify-error (rassoc-if #'null nil :key))
program-error)
(signals-error (rassoc-if #'null nil :key) program-error)
t)
(deftest rassoc-if.error.5
(classify-error (rassoc-if #'null nil 1 1))
program-error)
(signals-error (rassoc-if #'null nil 1 1) program-error)
t)
(deftest rassoc-if.error.6
(classify-error (rassoc-if #'null nil :bad t :allow-other-keys nil))
program-error)
(signals-error (rassoc-if #'null nil :bad t :allow-other-keys nil) program-error)
t)
(deftest rassoc-if.error.7
(classify-error (rassoc-if #'cons '((a . b)(c . d))))
program-error)
(signals-error (rassoc-if #'cons '((a . b)(c . d))) program-error)
t)
(deftest rassoc-if.error.8
(classify-error (rassoc-if #'car '((a . b)(c . d))))
type-error)
(signals-error (rassoc-if #'car '((a . b)(c . d))) type-error)
t)
(deftest rassoc-if.error.9
(classify-error (rassoc-if #'identity '((a . b)(c . d)) :key #'cons))
program-error)
(signals-error (rassoc-if #'identity '((a . b)(c . d)) :key #'cons) program-error)
t)
(deftest rassoc-if.error.10
(classify-error (rassoc-if #'identity '((a . b)(c . d)) :key #'car))
type-error)
(signals-error (rassoc-if #'identity '((a . b)(c . d)) :key #'car) type-error)
t)
(deftest rassoc-if.error.11
(classify-error (rassoc-if #'not '((a . b) . c)))
type-error)
(signals-error (rassoc-if #'not '((a . b) . c)) type-error)
t)
......@@ -265,41 +265,41 @@
;;; Error tests
(deftest rassoc.error.1
(classify-error (rassoc))
program-error)
(signals-error (rassoc) program-error)
t)
(deftest rassoc.error.2
(classify-error (rassoc nil))
program-error)
(signals-error (rassoc nil) program-error)
t)
(deftest rassoc.error.3
(classify-error (rassoc nil nil :bad t))
program-error)
(signals-error (rassoc nil nil :bad t) program-error)
t)
(deftest rassoc.error.4
(classify-error (rassoc nil nil :key))
program-error)
(signals-error (rassoc nil nil :key) program-error)
t)
(deftest rassoc.error.5
(classify-error (rassoc nil nil 1 1))
program-error)
(signals-error (rassoc nil nil 1 1) program-error)
t)
(deftest rassoc.error.6
(classify-error (rassoc nil nil :bad t :allow-other-keys nil))
program-error)
(signals-error (rassoc nil nil :bad t :allow-other-keys nil) program-error)
t)
(deftest rassoc.error.7
(classify-error (rassoc 'a '((b . a)(c . d)) :test #'identity))
program-error)
(signals-error (rassoc 'a '((b . a)(c . d)) :test #'identity) program-error)
t)
(deftest rassoc.error.8
(classify-error (rassoc 'a '((b . a)(c . d)) :test-not #'identity))
program-error)
(signals-error (rassoc 'a '((b . a)(c . d)) :test-not #'identity) program-error)
t)
(deftest rassoc.error.9
(classify-error (rassoc 'a '((b . a)(c . d)) :key #'cons))
program-error)
(signals-error (rassoc 'a '((b . a)(c . d)) :key #'cons) program-error)
t)
(deftest rassoc.error.10
(classify-error (rassoc 'z '((a . b) . c)))
type-error)
(signals-error (rassoc 'z '((a . b) . c)) type-error)
t)
......@@ -6,22 +6,21 @@
(in-package :cl-test)
(deftest rational.error.1
(classify-error (rational))
program-error)
(signals-error (rational) program-error)
t)
(deftest rational.error.2
(classify-error (rational 0 nil))
program-error)
(signals-error (rational 0 nil) program-error)
t)
(deftest rational.error.3
(classify-error (rational 0 0))
program-error)
(signals-error (rational 0 0) program-error)
t)
(deftest rational.error.4
(loop for x in *mini-universe*
unless (or (realp x)
(eq (eval `(classify-error (rational (quote ,x))))
'type-error))
(eval `(signals-error (rational ',x) type-error)))
collect x)
nil)
......
......@@ -6,22 +6,21 @@
(in-package :cl-test)
(deftest rationalize.error.1
(classify-error (rationalize))
program-error)
(signals-error (rationalize) program-error)
t)
(deftest rationalize.error.2
(classify-error (rationalize 0 nil))
program-error)
(signals-error (rationalize 0 nil) program-error)
t)
(deftest rationalize.error.3
(classify-error (rationalize 0 0))
program-error)
(signals-error (rationalize 0 0) program-error)
t)
(deftest rationalize.error.4
(loop for x in *mini-universe*
unless (or (realp x)
(eq (eval `(classify-error (rationalize (quote ,x))))
'type-error))
(eval `(signals-error (rationalize ',x) type-error)))
collect x)
nil)
......
......@@ -6,16 +6,16 @@
(in-package :cl-test)
(deftest rationalp.error.1
(classify-error (rationalp))
program-error)
(signals-error (rationalp) program-error)
t)
(deftest rationalp.error.2
(classify-error (rationalp 0 nil))
program-error)
(signals-error (rationalp 0 nil) program-error)
t)
(deftest rationalp.error.3
(classify-error (rationalp 'a 0))
program-error)
(signals-error (rationalp 'a 0) program-error)
t)
(deftest rationalp.1
(loop for x in *rationals*
......
......@@ -41,12 +41,12 @@
nil)
(deftest readtablep.error.1
(classify-error (readtablep))
program-error)
(signals-error (readtablep) program-error)
t)
(deftest readtablep.error.2
(classify-error (readtablep nil nil))
program-error)
(signals-error (readtablep nil nil) program-error)
t)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
......
......@@ -6,16 +6,16 @@
(in-package :cl-test)
(deftest realp.error.1
(classify-error (realp))
program-error)
(signals-error (realp) program-error)
t)
(deftest realp.error.2
(classify-error (realp 0 nil))
program-error)
(signals-error (realp 0 nil) program-error)
t)
(deftest realp.error.3
(classify-error (realp nil nil))
program-error)
(signals-error (realp nil nil) program-error)
t)
(deftest realp.1
(notnot-mv (realp 0))
......
......@@ -6,17 +6,17 @@
(in-package :cl-test)
(deftest realpart.error.1
(classify-error (realpart))
program-error)
(signals-error (realpart) program-error)
t)
(deftest realpart.error.2
(classify-error (realpart #c(1.0 2.0) nil))
program-error)
(signals-error (realpart #c(1.0 2.0) nil) program-error)
t)
(deftest realpart.error.3
(loop for x in *mini-universe*
unless (or (numberp x)
(eq (eval `(classify-error (realpart ',x))) 'type-error))
(eval `(signals-error (realpart ',x) type-error)))
collect x)
nil)
......
......@@ -169,44 +169,44 @@
;;;;;;;;
(deftest reduce.error.1
(classify-error (reduce 'cons 'a))
type-error)
(signals-error (reduce 'cons 'a) type-error)
t)
(deftest reduce.error.2
(classify-error (reduce))
program-error)
(signals-error (reduce) program-error)
t)
(deftest reduce.error.3
(classify-error (reduce #'list nil :start))
program-error)
(signals-error (reduce #'list nil :start) program-error)
t)
(deftest reduce.error.4
(classify-error (reduce #'list nil 'bad t))
program-error)
(signals-error (reduce #'list nil 'bad t) program-error)
t)
(deftest reduce.error.5
(classify-error (reduce #'list nil 'bad t :allow-other-keys nil))
program-error)
(signals-error (reduce #'list nil 'bad t :allow-other-keys nil) program-error)
t)
(deftest reduce.error.6
(classify-error (reduce #'list nil 1 2))
program-error)
(signals-error (reduce #'list nil 1 2) program-error)
t)
(deftest reduce.error.7
(classify-error (locally (reduce 'cons 'a) t))
type-error)
(signals-error (locally (reduce 'cons 'a) t) type-error)
t)
(deftest reduce.error.8
(classify-error (reduce #'identity '(a b c)))
program-error)
(signals-error (reduce #'identity '(a b c)) program-error)
t)
(deftest reduce.error.9
(classify-error (reduce #'cons '(a b c) :key #'cons))
program-error)
(signals-error (reduce #'cons '(a b c) :key #'cons) program-error)
t)
(deftest reduce.error.10
(classify-error (reduce #'cons '(a b c) :key #'car))
type-error)
(signals-error (reduce #'cons '(a b c) :key #'car) type-error)
t)
;;;;;;;;
......
......@@ -130,5 +130,5 @@
:good)
(deftest reinitialize-instance.error.2
(classify-error (reinitialize-instance))
program-error)
(signals-error (reinitialize-instance) program-error)
t)
......@@ -66,16 +66,16 @@
;;; Error tests
(deftest remhash.error.1
(classify-error (remhash))
program-error)
(signals-error (remhash) program-error)
t)
(deftest remhash.error.2
(classify-error (remhash 'a))
program-error)
(signals-error (remhash 'a) program-error)
t)
(deftest remhash.error.3
(classify-error (remhash 'a (make-hash-table) nil))
program-error)
(signals-error (remhash 'a (make-hash-table) nil) program-error)
t)
......
......@@ -195,75 +195,75 @@
;;; Error cases
(deftest remove-duplicates.error.1
(classify-error (remove-duplicates))
program-error)
(signals-error (remove-duplicates) program-error)
t)
(deftest remove-duplicates.error.2
(classify-error (remove-duplicates nil :start))
program-error)
(signals-error (remove-duplicates nil :start) program-error)
t)
(deftest remove-duplicates.error.3
(classify-error (remove-duplicates nil 'bad t))
program-error)
(signals-error (remove-duplicates nil 'bad t) program-error)
t)
(deftest remove-duplicates.error.4
(classify-error (remove-duplicates nil 'bad t :allow-other-keys nil))
program-error)
(signals-error (remove-duplicates nil 'bad t :allow-other-keys nil) program-error)
t)
(deftest remove-duplicates.error.5
(classify-error (remove-duplicates nil 1 2))
program-error)
(signals-error (remove-duplicates nil 1 2) program-error)
t)
(deftest remove-duplicates.error.6
(classify-error (remove-duplicates (list 'a 'b 'c) :test #'identity))
program-error)
(signals-error (remove-duplicates (list 'a 'b 'c) :test #'identity) program-error)
t)
(deftest remove-duplicates.error.7
(classify-error (remove-duplicates (list 'a 'b 'c) :test-not #'identity))
program-error)
(signals-error (remove-duplicates (list 'a 'b 'c) :test-not #'identity) program-error)
t)
(deftest remove-duplicates.error.8
(classify-error (remove-duplicates (list 'a 'b 'c) :key #'cons))
program-error)
(signals-error (remove-duplicates (list 'a 'b 'c) :key #'cons) program-error)
t)
(deftest remove-duplicates.error.9
(classify-error (remove-duplicates (list 'a 'b 'c) :key #'car))
type-error)
(signals-error (remove-duplicates (list 'a 'b 'c) :key #'car) type-error)
t)
;;;
(deftest delete-duplicates.error.1
(classify-error (delete-duplicates))
program-error)
(signals-error (delete-duplicates) program-error)
t)
(deftest delete-duplicates.error.2
(classify-error (delete-duplicates nil :start))
program-error)
(signals-error (delete-duplicates nil :start) program-error)
t)
(deftest delete-duplicates.error.3
(classify-error (delete-duplicates nil 'bad t))
program-error)
(signals-error (delete-duplicates nil 'bad t) program-error)
t)
(deftest delete-duplicates.error.4
(classify-error (delete-duplicates nil 'bad t :allow-other-keys nil))
program-error)
(signals-error (delete-duplicates nil 'bad t :allow-other-keys nil) program-error)
t)
(deftest delete-duplicates.error.5
(classify-error (delete-duplicates nil 1 2))
program-error)
(signals-error (delete-duplicates nil 1 2) program-error)
t)
(deftest delete-duplicates.error.6
(classify-error (delete-duplicates (list 'a 'b 'c) :test #'identity))
program-error)
(signals-error (delete-duplicates (list 'a 'b 'c) :test #'identity) program-error)
t)
(deftest delete-duplicates.error.7
(classify-error (delete-duplicates (list 'a 'b 'c) :test-not #'identity))
program-error)
(signals-error (delete-duplicates (list 'a 'b 'c) :test-not #'identity) program-error)
t)
(deftest delete-duplicates.error.8
(classify-error (delete-duplicates (list 'a 'b 'c) :key #'cons))
program-error)
(signals-error (delete-duplicates (list 'a 'b 'c) :key #'cons) program-error)
t)
(deftest delete-duplicates.error.9
(classify-error (delete-duplicates (list 'a 'b 'c) :key #'car))
type-error)
\ No newline at end of file
(signals-error (delete-duplicates (list 'a 'b 'c) :key #'car) type-error)
t)
\ No newline at end of file
......@@ -775,84 +775,84 @@
;;; Error cases
(deftest remove.error.1
(classify-error (remove))
program-error)
(signals-error (remove) program-error)
t)
(deftest remove.error.2
(classify-error (remove 'a))
program-error)
(signals-error (remove 'a) program-error)
t)
(deftest remove.error.3
(classify-error (remove 'a nil :key))
program-error)
(signals-error (remove 'a nil :key) program-error)
t)
(deftest remove.error.4
(classify-error (remove 'a nil 'bad t))
program-error)
(signals-error (remove 'a nil 'bad t) program-error)
t)
(deftest remove.error.5
(classify-error (remove 'a nil 'bad t :allow-other-keys nil))
program-error)
(signals-error (remove 'a nil 'bad t :allow-other-keys nil) program-error)
t)
(deftest remove.error.6
(classify-error (remove 'a nil 1 2))
program-error)
(signals-error (remove 'a nil 1 2) program-error)
t)
(deftest remove.error.7
(classify-error (remove 'a (list 'a 'b 'c) :test #'identity))
program-error)
(signals-error (remove 'a (list 'a 'b 'c) :test #'identity) program-error)
t)
(deftest remove.error.8
(classify-error (remove 'a (list 'a 'b 'c) :test-not #'identity))
program-error)
(signals-error (remove 'a (list 'a 'b 'c) :test-not #'identity) program-error)
t)
(deftest remove.error.9
(classify-error (remove 'a (list 'a 'b 'c) :key #'cons))
program-error)
(signals-error (remove 'a (list 'a 'b 'c) :key #'cons) program-error)
t)
(deftest remove.error.10
(classify-error (remove 'a (list 'a 'b 'c) :key #'car))
type-error)
(signals-error (remove 'a (list 'a 'b 'c) :key #'car) type-error)
t)
;;;
(deftest delete.error.1
(classify-error (delete))
program-error)
(signals-error (delete) program-error)
t)
(deftest delete.error.2
(classify-error (delete 'a))
program-error)
(signals-error (delete 'a) program-error)
t)
(deftest delete.error.3
(classify-error (delete 'a nil :key))
program-error)
(signals-error (delete 'a nil :key) program-error)
t)
(deftest delete.error.4
(classify-error (delete 'a nil 'bad t))
program-error)
(signals-error (delete 'a nil 'bad t) program-error)
t)
(deftest delete.error.5
(classify-error (delete 'a nil 'bad t :allow-other-keys nil))
program-error)
(signals-error (delete 'a nil 'bad t :allow-other-keys nil) program-error)
t)
(deftest delete.error.6
(classify-error (delete 'a nil 1 2))
program-error)
(signals-error (delete 'a nil 1 2) program-error)
t)
(deftest delete.error.7
(classify-error (delete 'a (list 'a 'b 'c) :test #'identity))
program-error)
(signals-error (delete 'a (list 'a 'b 'c) :test #'identity) program-error)
t)
(deftest delete.error.8
(classify-error (delete 'a (list 'a 'b 'c) :test-not #'identity))
program-error)
(signals-error (delete 'a (list 'a 'b 'c) :test-not #'identity) program-error)
t)
(deftest delete.error.9
(classify-error (delete 'a (list 'a 'b 'c) :key #'cons))
program-error)
(signals-error (delete 'a (list 'a 'b 'c) :key #'cons) program-error)
t)
(deftest delete.error.10
(classify-error (delete 'a (list 'a 'b 'c) :key #'car))
type-error)
(signals-error (delete 'a (list 'a 'b 'c) :key #'car) type-error)
t)
......@@ -144,6 +144,6 @@
;;;
(deftest rename-file.error.1
(classify-error (rename-file))
program-error)
(signals-error (rename-file) program-error)
t)
......@@ -660,26 +660,26 @@
;;; Error cases
(deftest replace.error.1
(classify-error (replace))
program-error)
(signals-error (replace) program-error)
t)
(deftest replace.error.2
(classify-error (replace nil))