Class ExceptionTypeConstraint
ExceptionTypeConstraint is a special version of ExactTypeConstraint used to provided detailed info about the exception thrown in an error message.
Inherited Members
Namespace: NUnit.Framework.Constraints
Assembly: nunit.framework.dll
Syntax
public class ExceptionTypeConstraint : ExactTypeConstraint, IConstraint, IResolveConstraint
Constructors
View SourceExceptionTypeConstraint(Type)
Constructs an ExceptionTypeConstraint
Declaration
public ExceptionTypeConstraint(Type type)
Parameters
Type | Name | Description |
---|---|---|
Type | type |
Methods
View SourceApplyTo<TActual>(TActual)
Applies the constraint to an actual value, returning a ConstraintResult.
Declaration
public override ConstraintResult ApplyTo<TActual>(TActual actual)
Parameters
Type | Name | Description |
---|---|---|
TActual | actual | The value to be tested |
Returns
Type | Description |
---|---|
ConstraintResult | A ConstraintResult |
Type Parameters
Name | Description |
---|---|
TActual |