Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
ansi-test
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
Operations
Operations
Incidents
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Karsten Poeck
ansi-test
Commits
1d84bb97
Commit
1d84bb97
authored
Jan 08, 2006
by
pfdietz
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed open stream problem in read-sequence tests
parent
19064914
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
19 additions
and
12 deletions
+19
-12
ansi-tests/read-sequence.lsp
ansi-tests/read-sequence.lsp
+19
-12
No files found.
ansi-tests/read-sequence.lsp
View file @
1d84bb97
...
...
@@ -188,18 +188,25 @@
(defmacro def-read-sequence-bv-test (name init args &rest expected)
`(deftest ,name
;; Create output file
(let ((os (open "temp.dat" :direction :output
:element-type '(unsigned-byte 8)
:if-exists :supersede)))
(loop for i in '(0 1 1 0 0 1 1 0 1 0 1 1 1 0)
do (write-byte i os))
(close os)
(let ((is (open "temp.dat" :direction :input
:element-type '(unsigned-byte 8)))
(bv (copy-seq ,init)))
(values
(read-sequence bv is ,@args)
bv)))
(progn
(let (os)
(unwind-protect
(progn
(setq os (open "temp.dat" :direction :output
:element-type '(unsigned-byte 8)
:if-exists :supersede))
(loop for i in '(0 1 1 0 0 1 1 0 1 0 1 1 1 0)
do (write-byte i os)))
(when os (close os))))
(let (is (bv (copy-seq ,init)))
(unwind-protect
(progn
(setq is (open "temp.dat" :direction :input
:element-type '(unsigned-byte 8)))
(values
(read-sequence bv is ,@args)
bv))
(when is (close is)))))
,@expected))
(def-read-sequence-bv-test read-sequence.bv.1 #*00000000000000 ()
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment