Export (0) Print
Expand All

ExpectedExceptionBaseAttribute.Verify Method

This API supports the .NET Framework infrastructure and is not intended to be used directly from your code.

Namespace:  Microsoft.VisualStudio.TestTools.UnitTesting
Assembly:  Microsoft.VisualStudio.QualityTools.UnitTestFramework (in Microsoft.VisualStudio.QualityTools.UnitTestFramework.dll)

protected internal abstract void Verify(
	Exception exception
)

Parameters

exception
Type: System.Exception

The exception that is thrown by the unit test.

Determines whether the exception thrown is the expected exception. If the method returns, the exception was the expected exception. If the method throws an exception, the exception was not the expected exception. The message from the thrown exception is included in the test result. The Assert class can be used for convenience to throw an exception. If Assert.Inconclusive is used and the assertion statement is executed, the test outcome is set to Inconclusive.

Show:
© 2014 Microsoft