Skip to content

Commit c050fc7

Browse files
committed
Make proxy tests a bit less noisy.
1 parent c18a7c4 commit c050fc7

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

lib/async/http/body/pipe.rb

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,6 @@ def reader(task)
5353

5454
@head.close_write
5555
rescue => error
56-
raise
5756
ensure
5857
@input.close(error)
5958

@@ -71,7 +70,6 @@ def writer(task)
7170
@output.write(chunk)
7271
end
7372
rescue => error
74-
raise
7573
ensure
7674
@output.close_write(error)
7775

test/async/http/proxy.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@
143143
end
144144
ensure
145145
Console.debug(self) {"Finished reading from upstream..."}
146-
stream.close_write
146+
stream.close_write unless stream.closed?
147147
end
148148

149149
writer = Async do |task|
@@ -155,7 +155,7 @@
155155
end
156156
ensure
157157
Console.debug(self) {"Finished writing to upstream..."}
158-
upstream.close_write
158+
upstream.close_write unless upstream.closed?
159159
end
160160

161161
reader.wait

0 commit comments

Comments
 (0)