client-dotnet/tests/INetMock.Client.IntegrationTest/INetMockFixture.cs

20 lines
563 B
C#
Raw Normal View History

using System;
namespace INetMock.Client.IntegrationTest;
public class INetMockFixture
{
private const string DefaultINetMockSocketPath = "unix:///var/run/inetmock/inetmock.sock";
public INetMockFixture()
{
INetMockSocketPath = Environment.GetEnvironmentVariable("INETMOCK_SOCKET") ?? DefaultINetMockSocketPath;
if (INetMockSocketPath.StartsWith("http:"))
{
AppContext.SetSwitch("System.Net.Http.SocketsHttpHandler.Http2UnencryptedSupport", true);
}
}
public string INetMockSocketPath { get; }
}