Click or drag to resize

ExceptionAssertThrowsTException Method (Action, String)

Checks if the exception of type TException was thrown.

Namespace:  Enkoni.Framework.Testing
Assembly:  Enkoni.Framework.Testing (in Enkoni.Framework.Testing.dll) Version: 1.3.0.1
Syntax
public static void Throws<TException>(
	Action action,
	string message
)
where TException : Exception

Parameters

action
Type: SystemAction
The action that should throw an exception of type TException.
message
Type: SystemString
The message that should be used when no exception was thrown.

Type Parameters

TException
The type of the exception that should be thrown.
Exceptions
ExceptionCondition
ExceptionAn exception that does not inherit from TException
See Also