File tree Expand file tree Collapse file tree 3 files changed +9
-2
lines changed
Expand file tree Collapse file tree 3 files changed +9
-2
lines changed Original file line number Diff line number Diff line change 1919 os :
2020 - ubuntu
2121 - macos
22+ - windows
2223
2324 ruby :
2425 - " 3.2"
4748
4849 - name : Run tests
4950 timeout-minutes : 10
50- run : bundle exec bake test
51+ run : bundle exec sus --verbose
Original file line number Diff line number Diff line change @@ -106,12 +106,14 @@ def sysclose
106106 end
107107 end
108108
109- if RUBY_VERSION >= "3.3"
109+ if RUBY_VERSION >= "3.3" # and RUBY_PLATFORM !~ /win32|mswin|mingw/
110110 def syswrite ( buffer )
111111 return @io . write ( buffer )
112112 end
113113 else
114114 def syswrite ( buffer )
115+ raise IOError , "stream closed" if @io . closed?
116+
115117 while true
116118 result = @io . write_nonblock ( buffer , exception : false )
117119
@@ -133,6 +135,8 @@ def syswrite(buffer)
133135
134136 # Reads data from the underlying stream as efficiently as possible.
135137 def sysread ( size , buffer )
138+ raise IOError , "stream closed" if @io . closed?
139+
136140 # Come on Ruby, why couldn't this just return `nil`? EOF is not exceptional. Every file has one.
137141 while true
138142 result = @io . read_nonblock ( size , buffer , exception : false )
Original file line number Diff line number Diff line change @@ -321,6 +321,8 @@ def before
321321 end
322322
323323 it "times out when writing" do
324+ skip "#write with timeout not supported on Windows" if RUBY_PLATFORM =~ /win32|mswin|mingw/
325+
324326 server . io . timeout = 0.001
325327
326328 expect do
You can’t perform that action at this time.
0 commit comments