Unit Testing with Fakes and Mocks in Visual Studio 2012


One of the basic tenets of unit testing is the code you are testing should not have dependencies on other code.  This guarantees that if a unit test fails, it is not caused by something other than the method under test.  In the case when a method does depend on other code, Fakes and Mocks can be used to intercept calls to code outside of the method under test.  This provides full control over your tests.  This session will explore the use of Stubs and Shims using Microsoft Fakes.  We will also look at how Mocks differ by enabling behavior verification using Moq.

Brian Minisi

Brian Minisi is a Principal Consultant for Neudesic.  A Microsoft MVP and ALM Ranger, Brian is a frequent speaker at code camps and user groups. He is also an organizer of the Philly ALM User Group and the Philly Azure User Group. Brian is also a board member of the TechBash conference held in the Poconos each year.  He has been working with Microsoft technologies since 1998 and has been working in .NET since 2001. He is passionate about architecture and all aspects of the application lifecycle, cloud and DevOps.