Assert.

DoesNotThrow(TestDelegate, string, object[]) Method

Summary

Asserts that a delegate does not throw an exception. If any exception is thrown, it is caught and a TCLite.AssertionException is thrown, ending the test and reporting it as a Failure.
Namespace
TCLite
Containing Type
Assert

Syntax

public static void DoesNotThrow(TestDelegate code, string message = null, params object[] args)

Remarks

This assertion is useful in converting an Error result due to an unexpected exception into a Failure.

Parameters

Name Type Description
code TestDelegate A TestDelegate
message string The message that will be displayed on failure
args object[] Arguments to be used in formatting the message

Return Value

Type Description
void