Add routing tests for all supported routes
This commit is contained in:
parent
b012617608
commit
90e46a58de
24 changed files with 1028 additions and 16 deletions
32
test/functional/oauth_controller_test.rb
Normal file
32
test/functional/oauth_controller_test.rb
Normal file
|
@ -0,0 +1,32 @@
|
|||
require File.dirname(__FILE__) + '/../test_helper'
|
||||
|
||||
class OauthControllerTest < ActionController::TestCase
|
||||
##
|
||||
# test all routes which lead to this controller
|
||||
def test_routes
|
||||
assert_routing(
|
||||
{ :path => "/oauth/revoke" },
|
||||
{ :controller => "oauth", :action => "revoke" }
|
||||
)
|
||||
assert_routing(
|
||||
{ :path => "/oauth/authorize" },
|
||||
{ :controller => "oauth", :action => "authorize" }
|
||||
)
|
||||
assert_routing(
|
||||
{ :path => "/oauth/token" },
|
||||
{ :controller => "oauth", :action => "token" }
|
||||
)
|
||||
assert_routing(
|
||||
{ :path => "/oauth/request_token" },
|
||||
{ :controller => "oauth", :action => "request_token" }
|
||||
)
|
||||
assert_routing(
|
||||
{ :path => "/oauth/access_token" },
|
||||
{ :controller => "oauth", :action => "access_token" }
|
||||
)
|
||||
assert_routing(
|
||||
{ :path => "/oauth/test_request" },
|
||||
{ :controller => "oauth", :action => "test_request" }
|
||||
)
|
||||
end
|
||||
end
|
Loading…
Add table
Add a link
Reference in a new issue