diff options
author | Mikel Lindsaar <raasdnil@gmail.com> | 2010-01-19 21:05:37 +1100 |
---|---|---|
committer | Mikel Lindsaar <raasdnil@gmail.com> | 2010-01-19 21:05:37 +1100 |
commit | 2107921000f4a186fed36e676d1ac089c8be1f99 (patch) | |
tree | 42f2188f058f8401d57f0d4c72063689a93e0419 /activerecord/test/models/company.rb | |
parent | ccb7d9def3c20037c9ed5989d8cae1ed68763f4f (diff) | |
parent | ed8501ef16fb2f5e4bd4d987740f5e5f62978400 (diff) | |
download | rails-2107921000f4a186fed36e676d1ac089c8be1f99.tar.gz rails-2107921000f4a186fed36e676d1ac089c8be1f99.tar.bz2 rails-2107921000f4a186fed36e676d1ac089c8be1f99.zip |
Merge branch 'master' of git://github.com/rails/rails into rails
Diffstat (limited to 'activerecord/test/models/company.rb')
-rw-r--r-- | activerecord/test/models/company.rb | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/activerecord/test/models/company.rb b/activerecord/test/models/company.rb index 7e93fda1eb..df5fd10b6b 100644 --- a/activerecord/test/models/company.rb +++ b/activerecord/test/models/company.rb @@ -45,7 +45,7 @@ class Firm < Company has_many :unvalidated_clients_of_firm, :foreign_key => "client_of", :class_name => "Client", :validate => false has_many :dependent_clients_of_firm, :foreign_key => "client_of", :class_name => "Client", :order => "id", :dependent => :destroy has_many :exclusively_dependent_clients_of_firm, :foreign_key => "client_of", :class_name => "Client", :order => "id", :dependent => :delete_all - has_many :limited_clients, :class_name => "Client", :order => "id", :limit => 1 + has_many :limited_clients, :class_name => "Client", :limit => 1 has_many :clients_like_ms, :conditions => "name = 'Microsoft'", :class_name => "Client", :order => "id" has_many :clients_with_interpolated_conditions, :class_name => "Client", :conditions => 'rating > #{rating}' has_many :clients_like_ms_with_hash_conditions, :conditions => { :name => 'Microsoft' }, :class_name => "Client", :order => "id" @@ -91,10 +91,8 @@ class Firm < Company end class DependentFirm < Company - # added order by id as in fixtures there are two accounts for Rails Core - # Oracle tests were failing because of that as the second fixture was selected - has_one :account, :foreign_key => "firm_id", :dependent => :nullify, :order => "id" - has_many :companies, :foreign_key => 'client_of', :order => "id", :dependent => :nullify + has_one :account, :foreign_key => "firm_id", :dependent => :nullify + has_many :companies, :foreign_key => 'client_of', :dependent => :nullify end class Client < Company |