Permalink
Browse files

Refactors test code for expressiveness

  • Loading branch information...
1 parent 764b57f commit 64fe87ead8f2c2f2230953ae6ea765f4c4375337 Thiago Arrais committed with mojodna Nov 18, 2008
Showing with 2 additions and 1 deletion.
  1. +2 −1 test/test_action_controller_request_proxy.rb
@@ -5,9 +5,10 @@
class ActionControllerRequestProxyTest < Test::Unit::TestCase
- def request_proxy(parameters)
+ def request_proxy(parameters={})
request = ActionController::TestRequest.new({}, parameters)
request.env['CONTENT_TYPE'] = 'application/x-www-form-urlencoded'
+ yield request if block_given?
OAuth::RequestProxy.proxy(request)
end

0 comments on commit 64fe87e

Please sign in to comment.