From dd793a00158b5968c0300016df3db67c26a88248 Mon Sep 17 00:00:00 2001 From: AntonioTerceiro Date: Tue, 9 Oct 2007 18:29:04 +0000 Subject: [PATCH] ActionItem78: creating route for change_password --- config/routes.rb | 2 +- test/integration/routing_test.rb | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/config/routes.rb b/config/routes.rb index 2c598c8..fc15bdb 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -19,7 +19,7 @@ ActionController::Routing::Routes.draw do |map| map.connect 'doc', :controller => 'doc' # user account controller - map.connect 'account/change_password/:hash', :controller => 'account', :action => 'change_password' + map.connect 'account/change_password/:code', :controller => 'account', :action => 'change_password' map.connect 'account/:action', :controller => 'account' diff --git a/test/integration/routing_test.rb b/test/integration/routing_test.rb index d5c7d4e..7ea14d4 100644 --- a/test/integration/routing_test.rb +++ b/test/integration/routing_test.rb @@ -21,6 +21,10 @@ class RoutingTest < ActionController::IntegrationTest assert_routing('/account', :controller => 'account', :action => 'index') end + def test_change_password + assert_routing('/account/change_password/90dfhga7sadgd0as6saas', :controller => 'account', :action => 'change_password', :code => '90dfhga7sadgd0as6saas') + end + def test_comatose_admin assert_routing('/myprofile/ze/cms', :profile => 'ze', :controller => 'cms', :action => 'index') end -- libgit2 0.21.2