Moq – Mocking a cast on an interface
Mocking a Cast on a Mocked Interface The Setup var mockedInterface = new Mock<IInterface>(); mockedInterface.As().Setup(i => i.MethodOnTheInterface()); Easy as that! Been working with Moq a fair bit recently. Some other Moq tips and tricks here.
Copy and paste this URL into your WordPress site to embed
Copy and paste this code into your site to embed