1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00
ruby--ruby/spec/ruby/library/net/http/httpgenericrequest/method_spec.rb

16 lines
515 B
Ruby
Raw Normal View History

require File.expand_path('../../../../../spec_helper', __FILE__)
require 'net/http'
describe "Net::HTTPGenericRequest#method" do
it "returns self's request method" do
request = Net::HTTPGenericRequest.new("POST", true, true, "/some/path")
request.method.should == "POST"
request = Net::HTTPGenericRequest.new("GET", false, true, "/some/path")
request.method.should == "GET"
request = Net::HTTPGenericRequest.new("BLA", true, true, "/some/path")
request.method.should == "BLA"
end
end