Sha256: 8f508fe11e1aa2c860a0c4c5009bdbad0cd745e1957174318223a5e2e8c424ce

Contents?: true

Size: 252 Bytes

Versions: 7

Compression:

Stored size: 252 Bytes

Contents

MockServer = Class.new

module ServerMock
  def receive_data(data)
    @server ||= MockServer.new
    @server.receive_data data, self
  end

  def send_data(data)
    super data.gsub("\n", "\r\n")
  end
end

def client
  @client ||= mock('Client')
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
ruby_ami-1.0.1 spec/support/mock_server.rb
ruby_ami-1.0.0 spec/support/mock_server.rb
ruby_ami-0.1.5 spec/support/mock_server.rb
ruby_ami-0.1.4 spec/support/mock_server.rb
ruby_ami-0.1.3 spec/support/mock_server.rb
ruby_ami-0.1.2 spec/support/mock_server.rb
ruby_ami-0.1.1 spec/support/mock_server.rb