blob: be8d78d5dd65cf870a0b549d65f1fb27e067a697 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
require "timeout"
module ServerUtils
def open_client_connection(scheme = :https)
io = StringIO.new
@_ccon = ClientConnection.new(io.method(:write))
@_ccon << Frame.new(type: :settings, stream_id: 0, flags: [:ack]).assemble
@_ccon << Frame.new(type: :settings, stream_id: 0).assemble
if block_given?
yield @_ccon
else
@_ccon
end
end
end
class Minitest::Test
include ServerUtils
end
|