mirror of
https://github.com/gui-cs/Terminal.Gui.git
synced 2025-12-26 15:57:56 +01:00
* touching publish.yml * Moved Examples into ./Examples * Moved Benchmarks into ./Tests * Moved Benchmarks into ./Tests * Moved UICatalog into ./Examples * Moved UICatalog into ./Examples 2 * Moved tests into ./Tests * Updated nuget
22 lines
529 B
C#
22 lines
529 B
C#
using Microsoft.Extensions.Logging;
|
|
|
|
namespace TerminalGuiFluentTesting;
|
|
|
|
internal class TextWriterLogger (TextWriter writer) : ILogger
|
|
{
|
|
public IDisposable? BeginScope<TState> (TState state) { return null; }
|
|
|
|
public bool IsEnabled (LogLevel logLevel) { return true; }
|
|
|
|
public void Log<TState> (
|
|
LogLevel logLevel,
|
|
EventId eventId,
|
|
TState state,
|
|
Exception? ex,
|
|
Func<TState, Exception?, string> formatter
|
|
)
|
|
{
|
|
writer.WriteLine (formatter (state, ex));
|
|
}
|
|
}
|