lib/capybara/rack_test_json/client.rb in capybara-json-0.3.0 vs lib/capybara/rack_test_json/client.rb in capybara-json-0.4.0
- old
+ new
@@ -8,10 +8,10 @@
def initialize(app, options)
@app, @options = app, options
end
- %w[ get post put delete ].each do |method|
+ %w[ get post put patch delete ].each do |method|
module_eval <<-DEF, __FILE__, __LINE__+1
def #{method}(uri, params = {}, env = {}, &block)
env = env.merge(:method => "#{method.upcase}", :params => params)
if options[:follow_redirect]
request_with_follow_redirect(uri, env, &block)