aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/test/schema/schema.rb
diff options
context:
space:
mode:
authorJeremy Kemper <jeremy@bitsweat.net>2008-01-31 07:50:15 +0000
committerJeremy Kemper <jeremy@bitsweat.net>2008-01-31 07:50:15 +0000
commitbe827f9348a703b3048cb7728d0de6d019279bd9 (patch)
tree951f051662b7c26754fa31ea05dce255523014ee /activerecord/test/schema/schema.rb
parente59978aa867ef07e16ad64f73f1ed5cafa98d0ea (diff)
downloadrails-be827f9348a703b3048cb7728d0de6d019279bd9.tar.gz
rails-be827f9348a703b3048cb7728d0de6d019279bd9.tar.bz2
rails-be827f9348a703b3048cb7728d0de6d019279bd9.zip
Fixed preloading belongs_to associations which reference a custom foreign key. References #9640.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8762 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'activerecord/test/schema/schema.rb')
-rw-r--r--activerecord/test/schema/schema.rb9
1 files changed, 9 insertions, 0 deletions
diff --git a/activerecord/test/schema/schema.rb b/activerecord/test/schema/schema.rb
index bdf128aecc..8ab2022f8b 100644
--- a/activerecord/test/schema/schema.rb
+++ b/activerecord/test/schema/schema.rb
@@ -358,4 +358,13 @@ ActiveRecord::Schema.define do
create_table 'warehouse-things', :force => true do |t|
t.integer :value
end
+
+ create_table :owners, :primary_key => :owner_id ,:force => true do |t|
+ t.string :name
+ end
+
+ create_table :pets, :primary_key => :pet_id ,:force => true do |t|
+ t.string :name
+ t.integer :owner_id, :integer
+ end
end