[rspec-users] modules and stub

Sarah Allen lists at ruby-forum.com
Mon May 25 00:03:21 EDT 2009

David Chelimsky wrote:
> Stub methods on objects, not modules. The method can be one that
> *comes from* a module, but you need to stub it on the specific object
> that is at play in the example.

That makes sense, except the code does this:

I'm not an expert with modules, but that looks like it is calling the 
method directly on the module without an object.  Is there any way for 
me to stub that?  or is that not a good thing to be doing?

Posted via http://www.ruby-forum.com/.

More information about the rspec-users mailing list