From a8c1fa4afd4abe6a5c975a164235600d1b8d8b4e Mon Sep 17 00:00:00 2001 From: Jon Leighton Date: Tue, 10 May 2011 23:35:01 +0100 Subject: Add test to specify that attributes from an association's conditions should be assigned without mass-assignment protection when a record is built on the association. --- activerecord/test/models/car.rb | 2 ++ 1 file changed, 2 insertions(+) (limited to 'activerecord/test/models/car.rb') diff --git a/activerecord/test/models/car.rb b/activerecord/test/models/car.rb index b036f0f5c9..de1864345a 100644 --- a/activerecord/test/models/car.rb +++ b/activerecord/test/models/car.rb @@ -2,6 +2,8 @@ class Car < ActiveRecord::Base has_many :bulbs has_many :foo_bulbs, :class_name => "Bulb", :conditions => { :name => 'foo' } + has_many :frickinawesome_bulbs, :class_name => "Bulb", :conditions => { :frickinawesome => true } + has_many :tyres has_many :engines has_many :wheels, :as => :wheelable -- cgit v1.2.3