From: Matt Amos Date: Wed, 28 Mar 2012 17:59:54 +0000 (+0100) Subject: Added tests for old_* redaction routes X-Git-Tag: live~5626 X-Git-Url: https://git.openstreetmap.org/rails.git/commitdiff_plain/d9e4e5836f69f2d5b2e845d79e04927cb783fbc3?hp=8bfb5cae8ad5aa2973349b128baa06d8b5ee5e7b;ds=inline Added tests for old_* redaction routes --- diff --git a/test/functional/old_node_controller_test.rb b/test/functional/old_node_controller_test.rb index 899e101f9..ff776d67f 100644 --- a/test/functional/old_node_controller_test.rb +++ b/test/functional/old_node_controller_test.rb @@ -19,6 +19,10 @@ class OldNodeControllerTest < ActionController::TestCase { :path => "/api/0.6/node/1/2", :method => :get }, { :controller => "old_node", :action => "version", :id => "1", :version => "2" } ) + assert_routing( + { :path => "/api/0.6/node/1/2/redact", :method => :post }, + { :controller => "old_node", :action => "redact", :id => "1", :version => "2" } + ) end ## diff --git a/test/functional/old_relation_controller_test.rb b/test/functional/old_relation_controller_test.rb index fa20e2fc9..55e8a7377 100644 --- a/test/functional/old_relation_controller_test.rb +++ b/test/functional/old_relation_controller_test.rb @@ -15,6 +15,10 @@ class OldRelationControllerTest < ActionController::TestCase { :path => "/api/0.6/relation/1/2", :method => :get }, { :controller => "old_relation", :action => "version", :id => "1", :version => "2" } ) + assert_routing( + { :path => "/api/0.6/relation/1/2/redact", :method => :post }, + { :controller => "old_relation", :action => "redact", :id => "1", :version => "2" } + ) end # ------------------------------------- diff --git a/test/functional/old_way_controller_test.rb b/test/functional/old_way_controller_test.rb index 84f0e04b0..2e9ec8263 100644 --- a/test/functional/old_way_controller_test.rb +++ b/test/functional/old_way_controller_test.rb @@ -15,6 +15,10 @@ class OldWayControllerTest < ActionController::TestCase { :path => "/api/0.6/way/1/2", :method => :get }, { :controller => "old_way", :action => "version", :id => "1", :version => "2" } ) + assert_routing( + { :path => "/api/0.6/way/1/2/redact", :method => :post }, + { :controller => "old_way", :action => "redact", :id => "1", :version => "2" } + ) end # -------------------------------------