aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/test/models
diff options
context:
space:
mode:
authorXavier Noria <fxn@hashref.com>2010-05-01 02:23:47 -0700
committerXavier Noria <fxn@hashref.com>2010-05-01 02:23:47 -0700
commitefba1d4227514a6ce4880910a6531b0a6c3c75aa (patch)
treedaff4155b8c19b915125ac0b0da458279358e743 /activerecord/test/models
parent81807e0fe2879e08563c91ee6809ab6d1d0bd081 (diff)
parent6c280f3398966ffba45069500ff43d632513fe44 (diff)
downloadrails-efba1d4227514a6ce4880910a6531b0a6c3c75aa.tar.gz
rails-efba1d4227514a6ce4880910a6531b0a6c3c75aa.tar.bz2
rails-efba1d4227514a6ce4880910a6531b0a6c3c75aa.zip
Merge commit 'rails/master'
Conflicts: railties/guides/source/index.html.erb
Diffstat (limited to 'activerecord/test/models')
-rw-r--r--activerecord/test/models/author.rb4
-rw-r--r--activerecord/test/models/contact.rb4
2 files changed, 7 insertions, 1 deletions
diff --git a/activerecord/test/models/author.rb b/activerecord/test/models/author.rb
index 025f6207f8..655b45bf57 100644
--- a/activerecord/test/models/author.rb
+++ b/activerecord/test/models/author.rb
@@ -104,6 +104,10 @@ class Author < ActiveRecord::Base
"#{id}-#{name}"
end
+ def social
+ %w(twitter github)
+ end
+
private
def log_before_adding(object)
@post_log << "before_adding#{object.id || '<new>'}"
diff --git a/activerecord/test/models/contact.rb b/activerecord/test/models/contact.rb
index dbfa57bf49..975a885331 100644
--- a/activerecord/test/models/contact.rb
+++ b/activerecord/test/models/contact.rb
@@ -13,4 +13,6 @@ class Contact < ActiveRecord::Base
column :preferences, :string
serialize :preferences
-end \ No newline at end of file
+
+ belongs_to :alternative, :class_name => 'Contact'
+end