Knocking and mocking

I was thinking about studying cigarette butts and taunts, and I know several available libraries for .Net: RhinoMocks, Moq, TypeMock ... and although I still don’t see the difference between the stubs very much, and it makes fun, I know that it is, and I could always find out about it.

I would like to know without being in TDD or anything like that:

  • Is the value of training? I am not so sure that I will learn all the small details about expectations or something else will pay off in this situation.

  • Is the increase in production so much bigger than the manual creation of my "dummy implementations"? I think so, since mocking / interrupting a class dynamically happens faster.

  • Which library would you recommend? Mock seems lighter.

  • What are the best resources (textbooks, books, videos ...) for dummies and more or less relevant? I would not want to know about the library, and when I download the latest version, understand that most of the API shown is no longer valid.

Thanks for all.

+3
source share
4 answers
  • Is the learning curve worth it? - Yes, it’s not so difficult. Once you know how to use a mocking structure, you will save load time in unit testing.

  • , ? - , . , , , , . , , .

  • ? - Moq Rhino Mocks .Net , . Rhino ( "AAA" ). AAA. , Moq Rhino "AAA", .

  • , Google, .

mocks stub, , (, ), . , .

+5

FakeItEasy , Faking Amazing!
.

+2

RhinoMocks, , . , (, , , , , :)) , , , . , , .

.

, , , .

0

Stub - , "" , .

Mock - , , .


- .

- . , , - . - , .

Moq , , .Net. .

0

Source: https://habr.com/ru/post/1774487/


All Articles