[rspec-users] Stubbing Observers in rails?

David Chelimsky dchelimsky at gmail.com
Mon Jul 30 14:12:52 EDT 2007

On 7/30/07, Doug Cole <dougcole at gmail.com> wrote:
> In most of my tests I'd like to be able to stub out the observers for my
> models, but I'm not sure the best way to do this.  I doesn't look like there
> is a way to stub all instance methods, and I don't seem to be able to stub
> early enough to stub out the observer as it's instantiated.  I can think of
> several hackish ways to get around it, but I was wondering if anyone could
> suggest a good solution?  Thanks!

If you're looking to stub all instances, why not use (what) Rails (calls) mocks?

> _______________________________________________
> rspec-users mailing list
> rspec-users at rubyforge.org
> http://rubyforge.org/mailman/listinfo/rspec-users

More information about the rspec-users mailing list