mirror of
https://github.com/wiremock/WireMock.Net.git
synced 2026-05-30 19:50:45 +02:00
Use try..catch to set encoding in WireMockConsoleLogger (#1104)
This commit is contained in:
@@ -14,9 +14,13 @@ public class WireMockConsoleLogger : IWireMockLogger
|
|||||||
/// Initializes a new instance of the <see cref="WireMockConsoleLogger"/> class.
|
/// Initializes a new instance of the <see cref="WireMockConsoleLogger"/> class.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public WireMockConsoleLogger()
|
public WireMockConsoleLogger()
|
||||||
|
{
|
||||||
|
try
|
||||||
{
|
{
|
||||||
Console.OutputEncoding = System.Text.Encoding.UTF8;
|
Console.OutputEncoding = System.Text.Encoding.UTF8;
|
||||||
}
|
}
|
||||||
|
catch { }
|
||||||
|
}
|
||||||
|
|
||||||
/// <see cref="IWireMockLogger.Debug"/>
|
/// <see cref="IWireMockLogger.Debug"/>
|
||||||
public void Debug(string formatString, params object[] args)
|
public void Debug(string formatString, params object[] args)
|
||||||
|
|||||||
Reference in New Issue
Block a user