[rspec-users] Stubs and Object Constructor
akleak at gmail.com
Mon Mar 21 00:38:20 EDT 2011
OK - I got this working using mocha and the 'any_instance' method.
A gist with working examples is here: https://gist.github.com/879029
It looks like rspec mocks had an 'any_instance' method, but it was removed
because it promoted 'bad practice'.
I'm curious to understand how 'any_instance' promotes bad practice. I found
it useful in my situation, to stub out slow network code that crushed my
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the rspec-users