Skip to content

Commit

Permalink
Revert "Add the options method to action_controller testcase."
Browse files Browse the repository at this point in the history
This reverts commit 0303c23.

Conflicts:
	actionpack/lib/action_controller/test_case.rb

REASON: It will conflict with a lot of test cases. Better to call
`process` directly since this is a very uncommon HTTP method.

Fixes #10638.
  • Loading branch information
rafaelfranca committed May 16, 2013
1 parent c273cb6 commit e92a065
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 11 deletions.
6 changes: 0 additions & 6 deletions actionpack/lib/action_controller/test_case.rb
Original file line number Diff line number Diff line change
Expand Up @@ -499,12 +499,6 @@ def head(action, *args)
process(action, "HEAD", *args)
end

# Simulate a OPTIONS request with the given parameters and set/volley the response.
# See +get+ for more details.
def options(action, *args)
process(action, "OPTIONS", *args)
end

def xml_http_request(request_method, action, parameters = nil, session = nil, flash = nil)
@request.env['HTTP_X_REQUESTED_WITH'] = 'XMLHttpRequest'
@request.env['HTTP_ACCEPT'] ||= [Mime::JS, Mime::HTML, Mime::XML, 'text/xml', Mime::ALL].join(', ')
Expand Down
5 changes: 0 additions & 5 deletions actionpack/test/controller/test_case_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -201,11 +201,6 @@ def test_head_params_as_sting
assert_raise(NoMethodError) { head :test_params, "document body", :id => 10 }
end

def test_options
options :test_params
assert_equal 200, @response.status
end

def test_process_without_flash
process :set_flash
assert_equal '><', flash['test']
Expand Down

0 comments on commit e92a065

Please sign in to comment.