X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=tests%2Fgray-streams.impure.lisp;h=585aa0ab01290d14f6f851e9b5b6de4f488d6fa6;hb=d147d512602d761a2dcdfded506dd1a8f9a140dc;hp=5f96206cb1a491999df607cfd7b4d28bd3e76549;hpb=bbfeb9a341eb81fdd80146f38548437b211dc280;p=sbcl.git diff --git a/tests/gray-streams.impure.lisp b/tests/gray-streams.impure.lisp index 5f96206..585aa0a 100644 --- a/tests/gray-streams.impure.lisp +++ b/tests/gray-streams.impure.lisp @@ -183,6 +183,19 @@ (assert (null (fresh-line our-char-output))) (write-char #\c our-char-output))) (format nil "a ~%b~%c"))) + +;;; Patches introduced in sbcl-0.6.11.5 made the pretty-print logic +;;; test not only *PRINT-PRETTY* but also PRETTY-STREAM-P in some +;;; cases. Try to verify that we don't end up doing tests like that on +;;; bare Gray streams and thus bogusly omitting pretty-printing +;;; operations. +(flet ((frob () + (with-output-to-string (string) + (let ((gray-output-stream (make-character-output-stream string))) + (format gray-output-stream + "~@~%"))))) + (assert (= 1 (count #\newline (let ((*print-pretty* nil)) (frob))))) + (assert (= 2 (count #\newline (let ((*print-pretty* t)) (frob)))))) ;;;; example classes for binary output