Obviously, I'm missing something very simple, can someone please explain how to stub an instance of an AR model method.
This does not work: @widget = Widget.first # Widget has an instance method called 'next_seriel_number' @widget.stub(:next_serial_number).and_return(43, nil) I know I could use 'any_instance', and that does work, expect that I need to return multiple values. And 'any_instance' does not work with returning multiple values. This does not work: Widget.any_instance.stub(:next_serial_number).and_return(43, nil) # only returns 43 _______________________________________________ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/listinfo/rspec-users