Im new to C#/.NET . But Ive been doing TDD for quite some time now. I wanted to what is the best framework that can be used for mocking objects while writing tests in c3
+5
A:
Popular options
Moq and Rhino are both regular mock/stub framework. TypeMock Isolator is a bit special, as it modifies the IL to allow mocking of types you have no control over. Some like this a lot. Others feel it is too intrusive.
Brian Rasmussen
2010-03-16 08:48:13
My recommendation is for Rhino Mocks - although the lambda syntax of Moq is nice, Rhino Mocks can do some things that Moq is unable to do as yet, for example, support for ref and out parameters. Haven't tried TypeMock but can imagine it being very useful when there is absolutely no way that one is able to change the code under test.
Russ Cam
2010-03-16 08:57:41
Also, Moq and Rhino are free, which is not the case of Typemock...
Mathias
2010-03-20 03:55:23