aboutsummaryrefslogtreecommitdiffstats
path: root/actionview/test
diff options
context:
space:
mode:
authorRafael Mendonça França <rafael.franca@plataformatec.com.br>2014-08-17 23:01:13 -0300
committerRafael Mendonça França <rafael.franca@plataformatec.com.br>2014-08-17 23:01:13 -0300
commitd2d809868c3eeb4d4a964382fc3df15cd5da70e4 (patch)
tree4f790872d6cb202b235ed21fc3c5ade6c4511399 /actionview/test
parent76883f92374c6395f13c16628e1d87d40b6d2399 (diff)
parent6b0e834a194d112585f41deba0a40780d68e38c6 (diff)
downloadrails-d2d809868c3eeb4d4a964382fc3df15cd5da70e4.tar.gz
rails-d2d809868c3eeb4d4a964382fc3df15cd5da70e4.tar.bz2
rails-d2d809868c3eeb4d4a964382fc3df15cd5da70e4.zip
Merge pull request #15889 from carnesmedia/model-name
Use #model_name on instances instead of classes
Diffstat (limited to 'actionview/test')
-rw-r--r--actionview/test/activerecord/polymorphic_routes_test.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/actionview/test/activerecord/polymorphic_routes_test.rb b/actionview/test/activerecord/polymorphic_routes_test.rb
index e220dcb8cb..0d97ddb2f6 100644
--- a/actionview/test/activerecord/polymorphic_routes_test.rb
+++ b/actionview/test/activerecord/polymorphic_routes_test.rb
@@ -34,8 +34,8 @@ class ModelDelegator < ActiveRecord::Base
end
class ModelDelegate
- def self.model_name
- ActiveModel::Name.new(self)
+ def model_name
+ ActiveModel::Name.new(self.class)
end
def to_param