From 21cb2ee81727ed78f3baaf3a5125f7e88ea259ee Mon Sep 17 00:00:00 2001 From: Toshi MARUYAMA Date: Thu, 23 Feb 2012 06:11:59 +0000 Subject: [PATCH] Rails3: test: scm: move "repository_path_hash" method in repositories routing test to test_helper.rb for common use Rails3 new route format returns path param as string not array. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8923 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- test/integration/routing/repositories_test.rb | 9 --------- test/test_helper.rb | 7 +++++++ 2 files changed, 7 insertions(+), 9 deletions(-) diff --git a/test/integration/routing/repositories_test.rb b/test/integration/routing/repositories_test.rb index 44fe7309e..14c835f37 100644 --- a/test/integration/routing/repositories_test.rb +++ b/test/integration/routing/repositories_test.rb @@ -366,13 +366,4 @@ class RoutingRepositoriesTest < ActionController::IntegrationTest { :controller => 'repositories', :action => 'remove_related_issue', :id => 'redmine', :repository_id => 'foo', :rev => '123', :issue_id => '25' } ) end - - private - - def repository_path_hash(arr) - hs = {} - hs[:path] = arr.join("/") - hs[:param] = arr - hs - end end diff --git a/test/test_helper.rb b/test/test_helper.rb index bf6d5b366..a9eedaba9 100644 --- a/test/test_helper.rb +++ b/test/test_helper.rb @@ -143,6 +143,13 @@ class ActiveSupport::TestCase File.directory?(repository_path(vendor)) end + def repository_path_hash(arr) + hs = {} + hs[:path] = arr.join("/") + hs[:param] = arr + hs + end + def assert_error_tag(options={}) assert_tag({:attributes => { :id => 'errorExplanation' }}.merge(options)) end