WriteNormalizedException(TestConsole, Exception, ExceptionFormats) Method
Writes the given exception to the
TestConsole
and returns a normalized string
representation of the exception, with file paths and line numbers sanitized.
public static string WriteNormalizedException(this TestConsole console, Exception ex, ExceptionFormats formats = Default)
- Namespace
- Spectre
.Console .Testing - Containing Type
- Test
Console Extensions
Parameters
- TestConsole console
- The
TestConsole
to write to. - Exception ex
- The exception to write and normalize.
- ExceptionFormats formats
- Optional formatting options for exception output.
Returns
- string