##// END OF EJS Templates
remove trailing white-spaces from test/integration/routing_test.rb....
Toshi MARUYAMA -
r6533:db8beabfa3f5
parent child
Show More
@@ -5,12 +5,12
5 5 # modify it under the terms of the GNU General Public License
6 6 # as published by the Free Software Foundation; either version 2
7 7 # of the License, or (at your option) any later version.
8 #
8 #
9 9 # This program is distributed in the hope that it will be useful,
10 10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 12 # GNU General Public License for more details.
13 #
13 #
14 14 # You should have received a copy of the GNU General Public License
15 15 # along with this program; if not, write to the Free Software
16 16 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
@@ -31,7 +31,7 class RoutingTest < ActionController::IntegrationTest
31 31 should_route :get, "/attachments/download/1", :controller => 'attachments', :action => 'download', :id => '1'
32 32 should_route :get, "/attachments/download/1/filename.ext", :controller => 'attachments', :action => 'download', :id => '1', :filename => 'filename.ext'
33 33 end
34
34
35 35 context "boards" do
36 36 should_route :get, "/projects/world_domination/boards", :controller => 'boards', :action => 'index', :project_id => 'world_domination'
37 37 should_route :get, "/projects/world_domination/boards/new", :controller => 'boards', :action => 'new', :project_id => 'world_domination'
@@ -42,7 +42,7 class RoutingTest < ActionController::IntegrationTest
42 42 should_route :post, "/projects/world_domination/boards/new", :controller => 'boards', :action => 'new', :project_id => 'world_domination'
43 43 should_route :post, "/projects/world_domination/boards/44/edit", :controller => 'boards', :action => 'edit', :project_id => 'world_domination', :id => '44'
44 44 should_route :post, "/projects/world_domination/boards/44/destroy", :controller => 'boards', :action => 'destroy', :project_id => 'world_domination', :id => '44'
45
45
46 46 end
47 47
48 48 context "documents" do
@@ -55,7 +55,7 class RoutingTest < ActionController::IntegrationTest
55 55 should_route :post, "/documents/567/edit", :controller => 'documents', :action => 'edit', :id => '567'
56 56 should_route :post, "/documents/567/destroy", :controller => 'documents', :action => 'destroy', :id => '567'
57 57 end
58
58
59 59 context "issues" do
60 60 # REST actions
61 61 should_route :get, "/issues", :controller => 'issues', :action => 'index'
@@ -74,7 +74,7 class RoutingTest < ActionController::IntegrationTest
74 74 should_route :get, "/projects/23/issues/new", :controller => 'issues', :action => 'new', :project_id => '23'
75 75 should_route :post, "/projects/23/issues", :controller => 'issues', :action => 'create', :project_id => '23'
76 76 should_route :post, "/issues.xml", :controller => 'issues', :action => 'create', :format => 'xml'
77
77
78 78 should_route :get, "/issues/64/edit", :controller => 'issues', :action => 'edit', :id => '64'
79 79 # TODO: Should use PUT
80 80 should_route :post, "/issues/64/edit", :controller => 'issues', :action => 'edit', :id => '64'
@@ -83,13 +83,13 class RoutingTest < ActionController::IntegrationTest
83 83 # TODO: Should use DELETE
84 84 should_route :post, "/issues/64/destroy", :controller => 'issues', :action => 'destroy', :id => '64'
85 85 should_route :delete, "/issues/1.xml", :controller => 'issues', :action => 'destroy', :id => '1', :format => 'xml'
86
86
87 87 # Extra actions
88 88 should_route :get, "/projects/23/issues/64/copy", :controller => 'issues', :action => 'new', :project_id => '23', :copy_from => '64'
89 89
90 90 should_route :get, "/issues/move/new", :controller => 'issue_moves', :action => 'new'
91 91 should_route :post, "/issues/move", :controller => 'issue_moves', :action => 'create'
92
92
93 93 should_route :post, "/issues/1/quoted", :controller => 'journals', :action => 'new', :id => '1'
94 94
95 95 should_route :get, "/issues/calendar", :controller => 'calendars', :action => 'show'
@@ -123,20 +123,20 class RoutingTest < ActionController::IntegrationTest
123 123 should_route :get, "/issues/1/relations", :controller => 'issue_relations', :action => 'index', :issue_id => '1'
124 124 should_route :get, "/issues/1/relations.xml", :controller => 'issue_relations', :action => 'index', :issue_id => '1', :format => 'xml'
125 125 should_route :get, "/issues/1/relations.json", :controller => 'issue_relations', :action => 'index', :issue_id => '1', :format => 'json'
126
126
127 127 should_route :post, "/issues/1/relations", :controller => 'issue_relations', :action => 'create', :issue_id => '1'
128 128 should_route :post, "/issues/1/relations.xml", :controller => 'issue_relations', :action => 'create', :issue_id => '1', :format => 'xml'
129 129 should_route :post, "/issues/1/relations.json", :controller => 'issue_relations', :action => 'create', :issue_id => '1', :format => 'json'
130
130
131 131 should_route :get, "/relations/23", :controller => 'issue_relations', :action => 'show', :id => '23'
132 132 should_route :get, "/relations/23.xml", :controller => 'issue_relations', :action => 'show', :id => '23', :format => 'xml'
133 133 should_route :get, "/relations/23.json", :controller => 'issue_relations', :action => 'show', :id => '23', :format => 'json'
134
134
135 135 should_route :delete, "/relations/23", :controller => 'issue_relations', :action => 'destroy', :id => '23'
136 136 should_route :delete, "/relations/23.xml", :controller => 'issue_relations', :action => 'destroy', :id => '23', :format => 'xml'
137 137 should_route :delete, "/relations/23.json", :controller => 'issue_relations', :action => 'destroy', :id => '23', :format => 'json'
138 138 end
139
139
140 140 context "issue reports" do
141 141 should_route :get, "/projects/567/issues/report", :controller => 'reports', :action => 'issue_report', :id => '567'
142 142 should_route :get, "/projects/567/issues/report/assigned_to", :controller => 'reports', :action => 'issue_report_details', :id => '567', :detail => 'assigned_to'
@@ -171,7 +171,7 class RoutingTest < ActionController::IntegrationTest
171 171 should_route :get, "/news/234", :controller => 'news', :action => 'show', :id => '234'
172 172 should_route :get, "/news/567/edit", :controller => 'news', :action => 'edit', :id => '567'
173 173 should_route :get, "/news/preview", :controller => 'previews', :action => 'news'
174
174
175 175 should_route :post, "/projects/567/news", :controller => 'news', :action => 'create', :project_id => '567'
176 176 should_route :post, "/news/567/comments", :controller => 'comments', :action => 'create', :id => '567'
177 177
@@ -195,7 +195,7 class RoutingTest < ActionController::IntegrationTest
195 195 should_route :get, "/projects/33/roadmap", :controller => 'versions', :action => 'index', :project_id => '33'
196 196 should_route :get, "/projects/33/activity", :controller => 'activities', :action => 'index', :id => '33'
197 197 should_route :get, "/projects/33/activity.atom", :controller => 'activities', :action => 'index', :id => '33', :format => 'atom'
198
198
199 199 should_route :post, "/projects", :controller => 'projects', :action => 'create'
200 200 should_route :post, "/projects.xml", :controller => 'projects', :action => 'create', :format => 'xml'
201 201 should_route :post, "/projects/33/files", :controller => 'files', :action => 'create', :project_id => '33'
@@ -210,14 +210,14 class RoutingTest < ActionController::IntegrationTest
210 210 should_route :delete, "/projects/1.xml", :controller => 'projects', :action => 'destroy', :id => '1', :format => 'xml'
211 211 should_route :delete, "/projects/64/enumerations", :controller => 'project_enumerations', :action => 'destroy', :project_id => '64'
212 212 end
213
213
214 214 context "queries" do
215 215 should_route :get, "/queries.xml", :controller => 'queries', :action => 'index', :format => 'xml'
216 216 should_route :get, "/queries.json", :controller => 'queries', :action => 'index', :format => 'json'
217
217
218 218 should_route :get, "/queries/new", :controller => 'queries', :action => 'new'
219 219 should_route :get, "/projects/redmine/queries/new", :controller => 'queries', :action => 'new', :project_id => 'redmine'
220
220
221 221 should_route :post, "/queries/new", :controller => 'queries', :action => 'new'
222 222 should_route :post, "/projects/redmine/queries/new", :controller => 'queries', :action => 'new', :project_id => 'redmine'
223 223 end
@@ -240,8 +240,7 class RoutingTest < ActionController::IntegrationTest
240 240 should_route :get, "/projects/redmine/repository/annotate/path/to/file.c", :controller => 'repositories', :action => 'annotate', :id => 'redmine', :path => %w[path to file.c]
241 241 should_route :get, "/projects/redmine/repository/changes/path/to/file.c", :controller => 'repositories', :action => 'changes', :id => 'redmine', :path => %w[path to file.c]
242 242 should_route :get, "/projects/redmine/repository/statistics", :controller => 'repositories', :action => 'stats', :id => 'redmine'
243
244
243
245 244 should_route :post, "/projects/redmine/repository/edit", :controller => 'repositories', :action => 'edit', :id => 'redmine'
246 245 end
247 246
@@ -335,27 +334,27 class RoutingTest < ActionController::IntegrationTest
335 334 # /projects/foo/versions is /projects/foo/roadmap
336 335 should_route :get, "/projects/foo/versions.xml", :controller => 'versions', :action => 'index', :project_id => 'foo', :format => 'xml'
337 336 should_route :get, "/projects/foo/versions.json", :controller => 'versions', :action => 'index', :project_id => 'foo', :format => 'json'
338
337
339 338 should_route :get, "/projects/foo/versions/new", :controller => 'versions', :action => 'new', :project_id => 'foo'
340
339
341 340 should_route :post, "/projects/foo/versions", :controller => 'versions', :action => 'create', :project_id => 'foo'
342 341 should_route :post, "/projects/foo/versions.xml", :controller => 'versions', :action => 'create', :project_id => 'foo', :format => 'xml'
343 342 should_route :post, "/projects/foo/versions.json", :controller => 'versions', :action => 'create', :project_id => 'foo', :format => 'json'
344
343
345 344 should_route :get, "/versions/1", :controller => 'versions', :action => 'show', :id => '1'
346 345 should_route :get, "/versions/1.xml", :controller => 'versions', :action => 'show', :id => '1', :format => 'xml'
347 346 should_route :get, "/versions/1.json", :controller => 'versions', :action => 'show', :id => '1', :format => 'json'
348
347
349 348 should_route :get, "/versions/1/edit", :controller => 'versions', :action => 'edit', :id => '1'
350
349
351 350 should_route :put, "/versions/1", :controller => 'versions', :action => 'update', :id => '1'
352 351 should_route :put, "/versions/1.xml", :controller => 'versions', :action => 'update', :id => '1', :format => 'xml'
353 352 should_route :put, "/versions/1.json", :controller => 'versions', :action => 'update', :id => '1', :format => 'json'
354
353
355 354 should_route :delete, "/versions/1", :controller => 'versions', :action => 'destroy', :id => '1'
356 355 should_route :delete, "/versions/1.xml", :controller => 'versions', :action => 'destroy', :id => '1', :format => 'xml'
357 356 should_route :delete, "/versions/1.json", :controller => 'versions', :action => 'destroy', :id => '1', :format => 'json'
358
357
359 358 should_route :put, "/projects/foo/versions/close_completed", :controller => 'versions', :action => 'close_completed', :project_id => 'foo'
360 359 should_route :post, "/versions/1/status_by", :controller => 'versions', :action => 'status_by', :id => '1'
361 360 end
@@ -373,7 +372,7 class RoutingTest < ActionController::IntegrationTest
373 372 should_route :get, "/projects/567/wiki/index", :controller => 'wiki', :action => 'index', :project_id => '567'
374 373 should_route :get, "/projects/567/wiki/date_index", :controller => 'wiki', :action => 'date_index', :project_id => '567'
375 374 should_route :get, "/projects/567/wiki/export", :controller => 'wiki', :action => 'export', :project_id => '567'
376
375
377 376 should_route :post, "/projects/567/wiki/CookBook_documentation/preview", :controller => 'wiki', :action => 'preview', :project_id => '567', :id => 'CookBook_documentation'
378 377 should_route :post, "/projects/22/wiki/ladida/rename", :controller => 'wiki', :action => 'rename', :project_id => '22', :id => 'ladida'
379 378 should_route :post, "/projects/22/wiki/ladida/protect", :controller => 'wiki', :action => 'protect', :project_id => '22', :id => 'ladida'
General Comments 0
You need to be logged in to leave comments. Login now