Making custom port tests optional.

This commit is contained in:
Alex Shinn 2011-12-17 15:57:32 +09:00
parent 24b43e367b
commit e2cae1558c

View file

@ -23,6 +23,12 @@
(call-with-input-string "abc\ndef"
(lambda (in) (let ((line (read-line in))) (list line (read-line in))))))
;; Custom ports are only supported with string streams (i.e. either
;; GNU fopencookie or BSD funopen).
(cond-expand
(string-streams
(test "null-output-port" #t
(let ((out (make-null-output-port)))
(write 1 out)
@ -51,6 +57,6 @@
(lambda (out)
(let ((out (make-filtered-output-port string-upcase out)))
(display "abc" out)
(close-output-port out)))))
(close-output-port out)))))))
(test-end)