mirror of
https://gitee.com/fudiwei/DotNetCore.SKIT.FlurlHttpClient.Wechat.git
synced 2026-03-10 00:13:36 +08:00
test: 设计代码分析工具,以规避拼写错误导致的 API 定义问题
This commit is contained in:
@@ -13,6 +13,7 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV3.UnitTests
|
||||
|
||||
using var stream = File.OpenRead("appsettings.local.json");
|
||||
using var json = JsonDocument.Parse(stream);
|
||||
|
||||
var config = json.RootElement.GetProperty("WechatConfig");
|
||||
WechatAppId = config.GetProperty("AppId").GetString();
|
||||
WechatMerchantId = config.GetProperty("MerchantId").GetString();
|
||||
@@ -20,6 +21,9 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV3.UnitTests
|
||||
WechatMerchantCertSerialNumber = config.GetProperty("MerchantCertSerialNumber").GetString();
|
||||
WechatMerchantCertPrivateKey = config.GetProperty("MerchantCertPrivateKey").GetString();
|
||||
WechatOpenId = config.GetProperty("OpenId").GetString();
|
||||
|
||||
ProjectSourceDirectory = json.RootElement.GetProperty("ProjectSourceDirectory").GetString();
|
||||
ProjectTestDirectory = json.RootElement.GetProperty("ProjectTestDirectory").GetString();
|
||||
}
|
||||
|
||||
public static readonly string WechatAppId;
|
||||
@@ -28,5 +32,8 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV3.UnitTests
|
||||
public static readonly string WechatMerchantCertSerialNumber;
|
||||
public static readonly string WechatMerchantCertPrivateKey;
|
||||
public static readonly string WechatOpenId;
|
||||
|
||||
public static readonly string ProjectSourceDirectory;
|
||||
public static readonly string ProjectTestDirectory;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user