On 16 Sep 2007, at 06:43, Pat Maddox wrote: > You can't assign mock objects to associations.
Actually I haven't had any trouble with e.g. @company = Company.new :name => 'BigCo' @mock_employee = mock_model(Employee, :name => 'Pat', :[]= => true, :save => true) @company.employees << @mock_employee (To be followed by, for example, @mock_employee.should_receive (:destroy); @company.destroy.) Is that unacceptable? Cheers, -Tom _______________________________________________ rspec-users mailing list [email protected] http://rubyforge.org/mailman/listinfo/rspec-users
