Sha256: b9cedf51a480ae6694eee8cd3a4fc7b6efad431d8dae2c299112ff0e41a668aa

Contents?: true

Size: 515 Bytes

Versions: 3

Compression:

Stored size: 515 Bytes

Contents

require 'cgi'

describe "CGI::QueryExtension#gateway_interface" do
  before(:each) do
    ENV['REQUEST_METHOD'], @old_request_method = "GET", ENV['REQUEST_METHOD']
    @cgi = CGI.new
  end

  after(:each) do
    ENV['REQUEST_METHOD'] = @old_request_method
  end

  it "returns ENV['GATEWAY_INTERFACE']" do
    old_value, ENV['GATEWAY_INTERFACE'] = ENV['GATEWAY_INTERFACE'], "CGI/1.1"
    begin
      @cgi.gateway_interface.should == "CGI/1.1"
    ensure
      ENV['GATEWAY_INTERFACE'] = old_value
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
rubysl-cgi-1.0.0 spec/queryextension/gateway_interface_spec.rb
rubysl-cgi-2.0.1 spec/queryextension/gateway_interface_spec.rb
rubysl-cgi-2.0.0 spec/queryextension/gateway_interface_spec.rb