[mocha-developer] stubs! method

James Mead jamesmead44 at gmail.com
Fri Aug 22 11:20:35 EDT 2008


2008/1/22 James Mead <jamesmead44 at gmail.com>

> On 21/01/2008, Jay Fields <jay at jayfields.com> wrote:
>
>> I think a warning is perfect for me on both scenarios.
>>
>
> Cool.


This is rather a belated reply to your original message [1] on the old
mailing list.

I don't know whether you've already seen it, but since version 0.9.0, you
have been able to do this...

   Mocha::Configuration.warn_when(:stubbing_method_unnecessarily)

OR

   Mocha::Configuration.prevent(:stubbing_method_unnecessarily)

More details here [2].

I hope that does what you need.
-- 
James.
http://blog.floehopper.org

[1] http://rubyforge.org/pipermail/mocha-developer/2008-January/000506.html
[2] http://mocha.rubyforge.org/classes/Mocha/Configuration.html


More information about the mocha-developer mailing list