From 9a72cd22cf427754a30af409c4651da2017296a8 Mon Sep 17 00:00:00 2001 From: Rick Olson Date: Sun, 19 Mar 2006 19:32:07 +0000 Subject: Don't classify the has_one class when eager loading, it is already singular. Add tests. (closes #4117) [jonathan@bluewire.net.nz] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3983 5ecf4fe2-1ee6-0310-87b1-e25e094e27de --- activerecord/test/fixtures/author.rb | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'activerecord/test/fixtures/author.rb') diff --git a/activerecord/test/fixtures/author.rb b/activerecord/test/fixtures/author.rb index 1dda0f837c..e510dd1992 100644 --- a/activerecord/test/fixtures/author.rb +++ b/activerecord/test/fixtures/author.rb @@ -28,6 +28,8 @@ class Author < ActiveRecord::Base has_many :nothings, :through => :kateggorisatons, :class_name => 'Category' + belongs_to :author_address + attr_accessor :post_log def after_initialize @@ -55,3 +57,7 @@ class Author < ActiveRecord::Base raise Exception.new("You can't add a post") end end + +class AuthorAddress < ActiveRecord::Base + has_one :author +end \ No newline at end of file -- cgit v1.2.3