summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2014-05-13 18:49:20 (GMT)
committerdgp <dgp@users.sourceforge.net>2014-05-13 18:49:20 (GMT)
commit07f07faf4b8c0bfb0ee5602e048c44b40d8a4e42 (patch)
treeb57b0b8196de12dd4e936fb9aaccdd0182e0b308 /tests
parent9265507b2cd7b3a0b6ab0d67987a53be415b9ab3 (diff)
parent63543e9ad0130ddeba54d3a9f97d49e4c7216189 (diff)
downloadtcl-07f07faf4b8c0bfb0ee5602e048c44b40d8a4e42.zip
tcl-07f07faf4b8c0bfb0ee5602e048c44b40d8a4e42.tar.gz
tcl-07f07faf4b8c0bfb0ee5602e048c44b40d8a4e42.tar.bz2
Refactored much management of the BLOCKED and EOF flags into ChanRead() then
began repairing some of the logic about them. Tests iogt-2.* now fail because they've been crafted as experiments recording the fine detail of reflected channel driver calls, and fixing the management of channel flags is changing that. zlib-8.5 also needed adjustment to reflect that an EOF set must come with an empty string read when flags are functioning properly.
Diffstat (limited to 'tests')
-rw-r--r--tests/io.test16
-rw-r--r--tests/zlib.test2
2 files changed, 15 insertions, 3 deletions
diff --git a/tests/io.test b/tests/io.test
index d05b882..8a8775e 100644
--- a/tests/io.test
+++ b/tests/io.test
@@ -6650,11 +6650,23 @@ test io-52.4 {TclCopyChannel} {fcopy} {
fconfigure $f1 -translation lf -blocking 0
fconfigure $f2 -translation cr -blocking 0
fcopy $f1 $f2 -size 40
- set result [list [fconfigure $f1 -blocking] [fconfigure $f2 -blocking]]
+ set result [list [fblocked $f1] [fconfigure $f1 -blocking] [fconfigure $f2 -blocking]]
+ close $f1
+ close $f2
+ lappend result [file size $path(test1)]
+} {0 0 0 40}
+test io-52.4.1 {TclCopyChannel} {fcopy} {
+ file delete $path(test1)
+ set f1 [open $thisScript]
+ set f2 [open $path(test1) w]
+ fconfigure $f1 -translation lf -blocking 0 -buffersize 10000000
+ fconfigure $f2 -translation cr -blocking 0
+ fcopy $f1 $f2 -size 40
+ set result [list [fblocked $f1] [fconfigure $f1 -blocking] [fconfigure $f2 -blocking]]
close $f1
close $f2
lappend result [file size $path(test1)]
-} {0 0 40}
+} {0 0 0 40}
test io-52.5 {TclCopyChannel, all} {fcopy} {
file delete $path(test1)
set f1 [open $thisScript]
diff --git a/tests/zlib.test b/tests/zlib.test
index 4e51ebb..2346ec7 100644
--- a/tests/zlib.test
+++ b/tests/zlib.test
@@ -215,7 +215,7 @@ test zlib-8.5 {transformation and flushing and fileevents: Bug 3525907} -setup {
set ::res
} -cleanup {
catch {close $r}
-} -result {qwertyuiop MIDDLE asdfghjkl}
+} -result {qwertyuiop MIDDLE asdfghjkl {}}
test zlib-8.6 {transformation and fconfigure} -setup {
set file [makeFile {} test.z]
set fd [open $file wb]