REST API for retrieving wiki pages (#7082).
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@10716 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
@@ -33,6 +33,16 @@ class RoutingWikiTest < ActionController::IntegrationTest
|
||||
{ :controller => 'wiki', :action => 'show', :project_id => '567',
|
||||
:id => 'lalala', :format => 'pdf' }
|
||||
)
|
||||
assert_routing(
|
||||
{ :method => 'get', :path => "/projects/567/wiki/lalala.xml" },
|
||||
{ :controller => 'wiki', :action => 'show', :project_id => '567',
|
||||
:id => 'lalala', :format => 'xml' }
|
||||
)
|
||||
assert_routing(
|
||||
{ :method => 'get', :path => "/projects/567/wiki/lalala.json" },
|
||||
{ :controller => 'wiki', :action => 'show', :project_id => '567',
|
||||
:id => 'lalala', :format => 'json' }
|
||||
)
|
||||
assert_routing(
|
||||
{ :method => 'get', :path => "/projects/1/wiki/CookBook_documentation/diff" },
|
||||
{ :controller => 'wiki', :action => 'diff', :project_id => '1',
|
||||
@@ -43,6 +53,16 @@ class RoutingWikiTest < ActionController::IntegrationTest
|
||||
{ :controller => 'wiki', :action => 'show', :project_id => '1',
|
||||
:id => 'CookBook_documentation', :version => '2' }
|
||||
)
|
||||
assert_routing(
|
||||
{ :method => 'get', :path => "/projects/1/wiki/CookBook_documentation/2.xml" },
|
||||
{ :controller => 'wiki', :action => 'show', :project_id => '1',
|
||||
:id => 'CookBook_documentation', :version => '2', :format => 'xml' }
|
||||
)
|
||||
assert_routing(
|
||||
{ :method => 'get', :path => "/projects/1/wiki/CookBook_documentation/2.json" },
|
||||
{ :controller => 'wiki', :action => 'show', :project_id => '1',
|
||||
:id => 'CookBook_documentation', :version => '2', :format => 'json' }
|
||||
)
|
||||
assert_routing(
|
||||
{ :method => 'get', :path => "/projects/1/wiki/CookBook_documentation/2/diff" },
|
||||
{ :controller => 'wiki', :action => 'diff', :project_id => '1',
|
||||
@@ -72,6 +92,14 @@ class RoutingWikiTest < ActionController::IntegrationTest
|
||||
{ :method => 'get', :path => "/projects/567/wiki/index" },
|
||||
{ :controller => 'wiki', :action => 'index', :project_id => '567' }
|
||||
)
|
||||
assert_routing(
|
||||
{ :method => 'get', :path => "/projects/567/wiki/index.xml" },
|
||||
{ :controller => 'wiki', :action => 'index', :project_id => '567', :format => 'xml' }
|
||||
)
|
||||
assert_routing(
|
||||
{ :method => 'get', :path => "/projects/567/wiki/index.json" },
|
||||
{ :controller => 'wiki', :action => 'index', :project_id => '567', :format => 'json' }
|
||||
)
|
||||
end
|
||||
|
||||
def test_wiki_resources
|
||||
|
||||
Reference in New Issue
Block a user