Name prefix should nest like path prefix

git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6592 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
This commit is contained in:
David Heinemeier Hansson
2007-04-27 05:07:56 +00:00
parent 0adf4a97c1
commit 8bf1f25254
2 changed files with 2 additions and 2 deletions

View File

@@ -45,7 +45,7 @@ module ActionController
end
def nesting_name_prefix
"#{singular}_"
"#{name_prefix}#{singular}_"
end

View File

@@ -208,7 +208,7 @@ class ResourcesTest < Test::Unit::TestCase
:path_prefix => 'threads/1/',
:options => { :thread_id => '1' }
assert_simply_restful_for :comments,
:name_prefix => 'message_',
:name_prefix => 'thread_message_',
:path_prefix => 'threads/1/messages/2/',
:options => { :thread_id => '1', :message_id => '2' }
end