[rspec-users] before_save model callback rspec testing

Csongor Bartus lists at ruby-forum.com
Fri Jun 20 11:23:16 EDT 2008

It might be ....

I've done this :

it "should encrypt password before save" do
      user = mock("User")

but I've got :

Spec::Mocks::MockExpectationError in 'User ActiveRecord Callbacks before 
save encrypt password'
Mock 'User' received unexpected message :save with (no args)
Posted via http://www.ruby-forum.com/.

More information about the rspec-users mailing list