Commit 63499c82 authored by pfdietz's avatar pfdietz
Browse files

Consolidated and renamed some defclass error tests (I created redundant tests by accident.)

parent 6ea2c636
......@@ -5,6 +5,9 @@
(in-package :cl-test)
;;; I created some redundant tests by accident. This list of
;;; tests could be reduced in size.
(deftest defclass.error.1
(classify-error
(defclass erroneous-class.1 ()
......@@ -83,4 +86,63 @@
(defclass erroneous-class.13 ()
(a b c)
(#.(gensym))))
program-error)
\ No newline at end of file
program-error)
(deftest defclass.error.14
(classify-error
(defclass defclass-error-14 nil
(foo foo)))
program-error)
(deftest defclass.error.15
(classify-error
(defclass defclass-error-15 nil
(foo (foo))))
program-error)
(deftest defclass.error.16
(classify-error
(defclass defclass-error-16 nil
((foo :initarg f1))
(:default-initargs :f1 10 :f1 20)))
program-error)
(deftest defclass.error.17
(classify-error
(defclass defclass-error-17 nil
((foo :initform 10 :initform 20 :reader defclass-error-4/foo))))
program-error)
(deftest defclass.error.18
(classify-error
(defclass defclass-error-18 nil
((foo :initform 10 :initform 10 :reader defclass-error-5/foo))))
program-error)
(deftest defclass.error.19
(classify-error
(defclass defclass-error-19 nil
((foo :initarg f1 :type t :type t :reader defclass-error-6/foo))))
program-error)
(deftest defclass.error.20
(classify-error
(defclass defclass-error-20 nil
((foo :initarg f1 :documentation "x" :reader defclass-error-7/foo
:documentation "x"))))
program-error)
(deftest defclass.error.21
(classify-error
(defclass defclass-error-21 ()
((foo #:unknown-slot-option nil))))
program-error)
(deftest defclass.error.22
(let ((option (gentemp "UNKNOWN-OPTION" (symbol-package :foo))))
(eval
`(classify-error
(defclass defclass-error-22 ()
(foo bar)
(,option nil)))))
program-error)
......@@ -5,70 +5,6 @@
(in-package :cl-test)
;;; Error tests (let's get them out of the way)
(deftest defclass.error.1
(classify-error
(defclass defclass-error-1 nil
(foo foo)))
program-error)
(deftest defclass.error.2
(classify-error
(defclass defclass-error-2 nil
(foo (foo))))
program-error)
(deftest defclass.error.3
(classify-error
(defclass defclass-error-3 nil
((foo :initarg f1))
(:default-initargs :f1 10 :f1 20)))
program-error)
(deftest defclass.error.4
(classify-error
(defclass defclass-error-4 nil
((foo :initform 10 :initform 20 :reader defclass-error-4/foo))))
program-error)
(deftest defclass.error.5
(classify-error
(defclass defclass-error-5 nil
((foo :initform 10 :initform 10 :reader defclass-error-5/foo))))
program-error)
(deftest defclass.error.6
(classify-error
(defclass defclass-error-6 nil
((foo :initarg f1 :type t :type t :reader defclass-error-6/foo))))
program-error)
(deftest defclass.error.7
(classify-error
(defclass defclass-error-7 nil
((foo :initarg f1 :documentation "x" :reader defclass-error-7/foo
:documentation "x"))))
program-error)
(deftest defclass.error.8
(classify-error
(defclass defclass-error-8 ()
((foo #:unknown-slot-option nil))))
program-error)
(deftest defclass.error.9
(let ((option (gentemp "UNKNOWN-OPTION" (symbol-package :foo))))
(eval
`(classify-error
(defclass defclass-error-9 ()
(foo bar)
(,option nil)))))
program-error)
;;; Now non-error tests
(defclass-with-tests defclass-1 nil nil)
(defclass-with-tests defclass-2 nil (slot1 slot2 slot3))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment