What is the purpose of mocking?
I have been following some ASP.NET MVC tutorials that use NUnit for testing and Moq for mocking. I am a little unclear about the mock
Mocking allows you to isolate your class under test from its dependencies. Generally, you create a mock for each dependency for the class under test and set up the mock to return expected values. You then provide the mock to your class under test instead of a real copy of the class that your class under test is dependent on. You can then use the mocking framework to check that the expected calls were made to the mock object(s) to ensure that your class under test is operating correctly.