@@ -18,7 +18,7 | |||
|
18 | 18 | require File.expand_path('../../../test_helper', __FILE__) |
|
19 | 19 | |
|
20 | 20 | class RoutingDocumentsTest < ActionController::IntegrationTest |
|
21 | def test_documents | |
|
21 | def test_documents_scoped_under_project | |
|
22 | 22 | assert_routing( |
|
23 | 23 | { :method => 'get', :path => "/projects/567/documents" }, |
|
24 | 24 | { :controller => 'documents', :action => 'index', :project_id => '567' } |
@@ -28,6 +28,13 class RoutingDocumentsTest < ActionController::IntegrationTest | |||
|
28 | 28 | { :controller => 'documents', :action => 'new', :project_id => '567' } |
|
29 | 29 | ) |
|
30 | 30 | assert_routing( |
|
31 | { :method => 'post', :path => "/projects/567/documents" }, | |
|
32 | { :controller => 'documents', :action => 'create', :project_id => '567' } | |
|
33 | ) | |
|
34 | end | |
|
35 | ||
|
36 | def test_documents | |
|
37 | assert_routing( | |
|
31 | 38 | { :method => 'get', :path => "/documents/22" }, |
|
32 | 39 | { :controller => 'documents', :action => 'show', :id => '22' } |
|
33 | 40 | ) |
@@ -36,10 +43,6 class RoutingDocumentsTest < ActionController::IntegrationTest | |||
|
36 | 43 | { :controller => 'documents', :action => 'edit', :id => '22' } |
|
37 | 44 | ) |
|
38 | 45 | assert_routing( |
|
39 | { :method => 'post', :path => "/projects/567/documents" }, | |
|
40 | { :controller => 'documents', :action => 'create', :project_id => '567' } | |
|
41 | ) | |
|
42 | assert_routing( | |
|
43 | 46 | { :method => 'put', :path => "/documents/22" }, |
|
44 | 47 | { :controller => 'documents', :action => 'update', :id => '22' } |
|
45 | 48 | ) |
General Comments 0
You need to be logged in to leave comments.
Login now