Commit 129afa55 authored by pfdietz's avatar pfdietz
Browse files

Tests for echo stream accessors.

parent 2905fc26
;-*- Mode: Lisp -*-
;;;; Author: Paul Dietz
;;;; Created: Thu Feb 12 04:30:40 2004
;;;; Contains: Tests of ECHO-STREAM-INPUT-STREAM
(in-package :cl-test)
(deftest echo-stream-input-stream.1
(let* ((is (make-string-input-stream "foo"))
(os (make-string-output-stream))
(s (make-echo-stream is os)))
(equalt (multiple-value-list (echo-stream-input-stream s))
(list is)))
t)
(deftest echo-stream-input-stream.error.1
(signals-error (echo-stream-input-stream) program-error)
t)
(deftest echo-stream-input-stream.error.2
(signals-error (let* ((is (make-string-input-stream "foo"))
(os (make-string-output-stream))
(s (make-echo-stream is os)))
(echo-stream-input-stream s nil))
program-error)
t)
;-*- Mode: Lisp -*-
;;;; Author: Paul Dietz
;;;; Created: Thu Feb 12 04:32:33 2004
;;;; Contains: Tests off ECHO-STREAM-OUTPUT-STREAM
(in-package :cl-test)
(deftest echo-stream-output-stream.1
(let* ((is (make-string-input-stream "foo"))
(os (make-string-output-stream))
(s (make-echo-stream is os)))
(equalt (multiple-value-list (echo-stream-output-stream s))
(list os)))
t)
(deftest echo-stream-output-stream.error.1
(signals-error (echo-stream-output-stream) program-error)
t)
(deftest echo-stream-output-stream.error.2
(signals-error (let* ((is (make-string-input-stream "foo"))
(os (make-string-output-stream))
(s (make-echo-stream is os)))
(echo-stream-output-stream s nil))
program-error)
t)
......@@ -41,4 +41,6 @@
(load "broadcast-stream-streams.lsp")
(load "make-two-way-stream.lsp")
(load "two-way-stream-input-stream.lsp")
(load "two-way-stream-output-stream.lsp")
\ No newline at end of file
(load "two-way-stream-output-stream.lsp")
(load "echo-stream-input-stream.lsp")
(load "echo-stream-output-stream.lsp")
\ No newline at end of file
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