ThrowsConstraint.Matches Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
Matches(Object) |
Executes the code of the delegate and captures any exception. If a non-null base constraint was provided, it applies that constraint to the exception. |
Matches<T>(ActualValueDelegate<T>) |
Matches(Object)
Executes the code of the delegate and captures any exception. If a non-null base constraint was provided, it applies that constraint to the exception.
public override bool Matches (object actual);
override this.Matches : obj -> bool
Parameters
- actual
- Object
A delegate representing the code to be tested
Returns
True if an exception is thrown and the constraint succeeds, otherwise false
Applies to
Matches<T>(ActualValueDelegate<T>)
public override bool Matches<T> (NUnit.Framework.Constraints.ActualValueDelegate<T> del);
override this.Matches : NUnit.Framework.Constraints.ActualValueDelegate<'T> -> bool
Type Parameters
- T