Skip to content
This repository was archived by the owner on Aug 29, 2024. It is now read-only.

Commit 01ad44c

Browse files
committed
Fix specs for streaming implementation.
1 parent 2355c96 commit 01ad44c

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

spec/async/io/stream_spec.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,7 @@
180180
io.write "Hello World"
181181
io.seek(0)
182182

183-
expect(subject.io).to receive(:read_nonblock).and_call_original.twice
183+
expect(subject.io).to receive(:sysread).and_call_original.twice
184184

185185
expect(subject.read).to be == "Hello World"
186186
expect(subject).to be_eof
@@ -190,7 +190,7 @@
190190
io.write "Hello World"
191191
io.seek(0)
192192

193-
expect(subject.io).to receive(:read_nonblock).and_call_original.once
193+
expect(subject.io).to receive(:sysread).and_call_original.once
194194

195195
expect(subject.read_partial(4)).to be == "Hell"
196196
expect(subject).to_not be_eof
@@ -275,7 +275,7 @@
275275
end
276276

277277
it "should avoid calling read" do
278-
expect(subject.io).to receive(:read_nonblock).and_call_original.once
278+
expect(subject.io).to receive(:sysread).and_call_original.once
279279

280280
expect(subject.read_partial(12)).to be == "Hello World!"
281281
end

0 commit comments

Comments
 (0)