btcpayserver/BTCPayServer.Tests/ChargeTester.cs

22 lines
747 B
C#
Raw Normal View History

using BTCPayServer.Lightning;
using BTCPayServer.Lightning.Charge;
using NBitcoin;
namespace BTCPayServer.Tests
{
public class ChargeTester
{
private readonly ServerTester _Parent;
public ChargeTester(ServerTester serverTester, string environmentName, string defaultValue, string defaultHost, Network network)
{
this._Parent = serverTester;
var url = serverTester.GetEnvironment(environmentName, defaultValue);
2018-07-01 09:10:17 +02:00
Client = (ChargeClient)LightningClientFactory.CreateClient(url, network);
P2PHost = _Parent.GetEnvironment(environmentName + "_HOST", defaultHost);
2020-06-28 10:55:27 +02:00
}
public ChargeClient Client { get; set; }
public string P2PHost { get; }
}
}