Sha256: e6e86f8584a76ae504f3d984cc4f09e8de4dcfa2afb2c1c3d3b0f9d94fcc0caf

Contents?: true

Size: 552 Bytes

Versions: 5

Compression:

Stored size: 552 Bytes

Contents

require 'spec_helper'
require 'capybara/webkit/connection'

describe Capybara::Webkit::Connection do
  it "sets appropriate options on its socket" do
    socket = double("socket")
    server = double(:Server, start: nil, port: 123)
    TCPSocket.stub(:open).and_return(socket)
    if defined?(Socket::TCP_NODELAY)
      socket.
        should_receive(:setsockopt).
        with(Socket::IPPROTO_TCP, Socket::TCP_NODELAY, true)
    else
      socket.should_not_receive(:setsockopt)
    end

    Capybara::Webkit::Connection.new(server: server)
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
capybara-webkit-1.12.0 spec/connection_spec.rb
capybara-webkit-1.11.1 spec/connection_spec.rb
capybara-webkit-1.11.0 spec/connection_spec.rb
capybara-webkit-1.10.1 spec/connection_spec.rb
capybara-webkit-1.10.0 spec/connection_spec.rb