From d9e4e5836f69f2d5b2e845d79e04927cb783fbc3 Mon Sep 17 00:00:00 2001 From: Matt Amos Date: Wed, 28 Mar 2012 18:59:54 +0100 Subject: [PATCH 1/1] Added tests for old_* redaction routes --- test/functional/old_node_controller_test.rb | 4 ++++ test/functional/old_relation_controller_test.rb | 4 ++++ test/functional/old_way_controller_test.rb | 4 ++++ 3 files changed, 12 insertions(+) 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 # ------------------------------------- -- 2.43.2