Commit 27483f8d authored by pfdietz's avatar pfdietz
Browse files

Trim random failure lists

parent c0034486
......@@ -51,13 +51,14 @@
;;; Random printing
(deftest print.cons.random.1
(loop
for x = (make-random-cons-tree (random 100))
repeat 500
nconc (randomly-check-readability x))
(trim-list
(loop
for x = (make-random-cons-tree (random 100))
repeat 500
nconc (randomly-check-readability x))
10)
nil)
;;; Printing with *print-length*
(deftest print.cons.length.1
......
......@@ -144,11 +144,12 @@
;;; Random tests
(deftest print.string.random.1
(loop for len = (1+ (random 5))
for s = (coerce (loop repeat len collect (random-from-seq +standard-chars+))
'string)
repeat 1000
append (randomly-check-readability s))
(trim-list
(loop for len = (1+ (random 5))
for s = (coerce (loop repeat len
collect (random-from-seq +standard-chars+))
'string)
repeat 1000
append (randomly-check-readability s))
10)
nil)
......@@ -248,41 +248,49 @@
;;; Readability tests
(deftest print.vector.random.1
(loop for v in *universe*
when (vectorp v)
nconc
(loop repeat 10
nconc (randomly-check-readability
v :test #'equalp
:can-fail (not (subtypep t (array-element-type v))))))
(trim-list
(loop for v in *universe*
when (vectorp v)
nconc
(loop repeat 10
nconc (randomly-check-readability
v :test #'equalp
:can-fail (not (subtypep t (array-element-type v))))))
10)
nil)
(deftest print.vector.random.2
(loop for i from 2 to 100
for type = `(unsigned-byte ,i)
for v = (make-array '(4) :element-type type
:initial-contents '(1 3 2 0))
nconc
(loop repeat 10
nconc (randomly-check-readability v :test #'equalp
:can-fail t)))
(trim-list
(loop for i from 2 to 100
for type = `(unsigned-byte ,i)
for v = (make-array '(4) :element-type type
:initial-contents '(1 3 2 0))
nconc
(loop repeat 10
nconc (randomly-check-readability v :test #'equalp
:can-fail t)))
10)
nil)
(deftest print.vector.random.3
(loop for i from 2 to 100
for type = `(signed-byte ,i)
for v = (make-array '(4) :element-type type
:initial-contents '(-1 1 0 -2))
nconc
(loop repeat 10
nconc (randomly-check-readability v :test #'equalp
:can-fail t)))
(trim-list
(loop for i from 2 to 100
for type = `(signed-byte ,i)
for v = (make-array '(4) :element-type type
:initial-contents '(-1 1 0 -2))
nconc
(loop repeat 10
nconc (randomly-check-readability v :test #'equalp
:can-fail t)))
10)
nil)
(deftest print.vector.random.4
(loop for v = (make-random-vector (1+ (random 100)))
repeat 1000
nconc (randomly-check-readability v :test #'equalp))
(trim-list
(loop for v = (make-random-vector (1+ (random 100)))
repeat 1000
nconc (randomly-check-readability v :test #'equalp))
10)
nil)
;;; *print-length* checks
......
Supports Markdown
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