Productivity
Testing
When asserting an expected call for its number of occurrences or may be just to verify if the setup/arrange is acted as intended, the tool generally raises assertion that points us to the reason why the test failed. Different mocking tools use different exception classes therefore there is no common way to consolidate them. However, if we just take a look into the test framework unless its some alien one, they all have a common underlying structure for Assert.Throws or ExpectedException (MSTest). MS Test (C# and Silverlight) Microsoft.VisualStudio.TestTools.UnitTesting.AssertFailedException NUnit NUnit.Framework.AssertionException XUnit Xunit.Sdk.AssertException MSpec Machine.Specifications.SpecificationException MbUnit Gallio.Framework.Assertions.AssertionException So the point here is that if we just use the existing exception class rather...