Wasting Time
Ale, music and enjoying life.
Posted on August 16, 2017 by admin
Leave a Comment
var mockedInterface = new Mock<IInterface>(); mockedInterface.As().Setup(i => i.MethodOnTheInterface()); Easy as that!
var mockedInterface = new Mock<IInterface>(); mockedInterface.As().Setup(i => i.MethodOnTheInterface());
Been working with Moq a fair bit recently. Some other Moq tips and tricks here.
Category: Comps Tags: Moq, nunit, unit testing