[rspec-users] Class method not being stubbed

Nick Hoffman nick at deadorange.com
Sun May 24 16:44:07 EDT 2009

>> Hi Fernando. I'm not sure what you mean by "the code never gets out of
>> this require statement".
> I should have said 'the interpreter never ...'

Ah, I understand what you mean now.

>> However, that doesn't really matter. The call to #require shouldn't
>> happen, because the method is supposed to be stubbed out.
> You are making a lot of suppositions that are not obvious to us. Nowhere
> in your pastie is your require call stubbed.

I'm not sure why the call to #require would need to be stubbed.

What I'm trying to say is that I've set a message expectation on
AdSenseHeavenParser#parse , which should prevent the method from being
called in the first place.


More information about the rspec-users mailing list