Re: [rspec-users] ActiveRecord::Base.should_receive(:find) fails

2009-02-19 Thread David Chelimsky
On Thu, Feb 19, 2009 at 12:34 PM, Tero Tilus wrote: > I've got an AR-model with some find-magic I want to test. When I have > > ActiveRecord::Base.should_receive(:find).with(anything(),assert_options) > MyModel.find(:all,find_options) MyModel != ActiveRecord::Base Try this MyModel.should_rec

[rspec-users] ActiveRecord::Base.should_receive(:find) fails

2009-02-19 Thread Tero Tilus
I've got an AR-model with some find-magic I want to test. When I have ActiveRecord::Base.should_receive(:find).with(anything(),assert_options) MyModel.find(:all,find_options) in my example find-method somehow disappears alltogether and I get NoMethodError in 'MyModel find-options are pass