[Rspec-devel] define_instance_method, stub_with, and mock_with
dastels at daveastels.com
Sun Aug 27 17:11:35 EDT 2006
-----BEGIN PGP SIGNED MESSAGE-----
On 27-Aug-06, at 4:51 PM, David Chelimsky wrote:
> As for the idea you are presenting, in general, I think that mocking
> methods on real instances is a risky proposition. I've seen this
> result in tests that are very difficult to understand when they fail,
> as some methods on the instance are mocked and some are not. I also
> have yet to see a case where using partial mocks is a better
> decision than improving the decoupling in the system under test.
> That's just my 2 cents. Anyone else?
I agree. Partial mocks can get very confusing, very easily.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.3 (Darwin)
-----END PGP SIGNATURE-----
More information about the Rspec-devel