From d95b1026a1ba7e988fe8067d9094603e35e96128 Mon Sep 17 00:00:00 2001 From: Fu Diwei Date: Mon, 29 Nov 2021 11:53:38 +0800 Subject: [PATCH] test --- test/SKIT.FlurlHttpClient.Wechat.Ads.UnitTests/TestConfigs.cs | 4 ++-- .../appsettings.json | 2 +- test/SKIT.FlurlHttpClient.Wechat.Api.UnitTests/TestConfigs.cs | 4 ++-- .../appsettings.json | 2 +- .../TestConfigs.cs | 4 ++-- .../appsettings.json | 2 +- .../TestConfigs.cs | 4 ++-- .../appsettings.json | 2 +- .../SKIT.FlurlHttpClient.Wechat.Work.UnitTests/TestConfigs.cs | 4 ++-- .../appsettings.json | 2 +- 10 files changed, 15 insertions(+), 15 deletions(-) diff --git a/test/SKIT.FlurlHttpClient.Wechat.Ads.UnitTests/TestConfigs.cs b/test/SKIT.FlurlHttpClient.Wechat.Ads.UnitTests/TestConfigs.cs index 4fed4a9c..eb5dd41c 100644 --- a/test/SKIT.FlurlHttpClient.Wechat.Ads.UnitTests/TestConfigs.cs +++ b/test/SKIT.FlurlHttpClient.Wechat.Ads.UnitTests/TestConfigs.cs @@ -16,7 +16,7 @@ namespace SKIT.FlurlHttpClient.Wechat.Ads.UnitTests using var stream = File.OpenRead("appsettings.local.json"); using var jdoc = JsonDocument.Parse(stream); - var config = jdoc.RootElement.GetProperty("WechatConfig"); + var config = jdoc.RootElement.GetProperty("TestConfig"); WechatAgencyId = config.GetProperty("AgencyId").GetString(); WechatAgencyAppId = config.GetProperty("AgencyAppId").GetString(); WechatAgencyApiKey = config.GetProperty("AgencyApiKey").GetString(); @@ -27,7 +27,7 @@ namespace SKIT.FlurlHttpClient.Wechat.Ads.UnitTests } catch (Exception ex) { - throw new Exception("加载配置文件 appsettings.local.json 失败", ex); + throw new Exception("加载配置文件 appsettings.local.json 失败,请查看 `InnerException` 了解具体失败原因", ex); } } diff --git a/test/SKIT.FlurlHttpClient.Wechat.Ads.UnitTests/appsettings.json b/test/SKIT.FlurlHttpClient.Wechat.Ads.UnitTests/appsettings.json index 2b17d6a5..20ff060d 100644 --- a/test/SKIT.FlurlHttpClient.Wechat.Ads.UnitTests/appsettings.json +++ b/test/SKIT.FlurlHttpClient.Wechat.Ads.UnitTests/appsettings.json @@ -1,5 +1,5 @@ { - "WechatConfig": { + "TestConfig": { "AgencyId": "请在此填写用于测试的微信广告 AgencyId", "AgencyAppId": "请在此填写用于测试的微信广告 AgencyAppId", "AgencyApiKey": "请在此填写用于测试的微信广告 AgencyApiKey", diff --git a/test/SKIT.FlurlHttpClient.Wechat.Api.UnitTests/TestConfigs.cs b/test/SKIT.FlurlHttpClient.Wechat.Api.UnitTests/TestConfigs.cs index 07228c2b..05714b23 100644 --- a/test/SKIT.FlurlHttpClient.Wechat.Api.UnitTests/TestConfigs.cs +++ b/test/SKIT.FlurlHttpClient.Wechat.Api.UnitTests/TestConfigs.cs @@ -16,7 +16,7 @@ namespace SKIT.FlurlHttpClient.Wechat.Api.UnitTests using var stream = File.OpenRead("appsettings.local.json"); using var jdoc = JsonDocument.Parse(stream); - var config = jdoc.RootElement.GetProperty("WechatConfig"); + var config = jdoc.RootElement.GetProperty("TestConfig"); WechatAppId = config.GetProperty("AppId").GetString(); WechatAppSecret = config.GetProperty("AppSecret").GetString(); WechatAccessToken = config.GetProperty("AccessToken").GetString(); @@ -27,7 +27,7 @@ namespace SKIT.FlurlHttpClient.Wechat.Api.UnitTests } catch (Exception ex) { - throw new Exception("加载配置文件 appsettings.local.json 失败", ex); + throw new Exception("加载配置文件 appsettings.local.json 失败,请查看 `InnerException` 了解具体失败原因", ex); } } diff --git a/test/SKIT.FlurlHttpClient.Wechat.Api.UnitTests/appsettings.json b/test/SKIT.FlurlHttpClient.Wechat.Api.UnitTests/appsettings.json index a51e04e6..afbea056 100644 --- a/test/SKIT.FlurlHttpClient.Wechat.Api.UnitTests/appsettings.json +++ b/test/SKIT.FlurlHttpClient.Wechat.Api.UnitTests/appsettings.json @@ -1,5 +1,5 @@ { - "WechatConfig": { + "TestConfig": { "AppId": "请在此填写用于测试的微信 AppId", "AppSecret": "请在此填写用于测试的微信 AppSecret", "AccessToken": "请在此填写用于测试的微信 AccessToken", diff --git a/test/SKIT.FlurlHttpClient.Wechat.OpenAI.UnitTests/TestConfigs.cs b/test/SKIT.FlurlHttpClient.Wechat.OpenAI.UnitTests/TestConfigs.cs index ab49a0d5..bd543053 100644 --- a/test/SKIT.FlurlHttpClient.Wechat.OpenAI.UnitTests/TestConfigs.cs +++ b/test/SKIT.FlurlHttpClient.Wechat.OpenAI.UnitTests/TestConfigs.cs @@ -16,7 +16,7 @@ namespace SKIT.FlurlHttpClient.Wechat.OpenAI.UnitTests using var stream = File.OpenRead("appsettings.local.json"); using var jdoc = JsonDocument.Parse(stream); - var config = jdoc.RootElement.GetProperty("WechatConfig"); + var config = jdoc.RootElement.GetProperty("TestConfig"); WechatClientId = config.GetProperty("ClientId").GetString(); WechatClientKey = config.GetProperty("ClientKey").GetString(); WechatAppId = config.GetProperty("AppId").GetString(); @@ -29,7 +29,7 @@ namespace SKIT.FlurlHttpClient.Wechat.OpenAI.UnitTests } catch (Exception ex) { - throw new Exception("加载配置文件 appsettings.local.json 失败", ex); + throw new Exception("加载配置文件 appsettings.local.json 失败,请查看 `InnerException` 了解具体失败原因", ex); } } diff --git a/test/SKIT.FlurlHttpClient.Wechat.OpenAI.UnitTests/appsettings.json b/test/SKIT.FlurlHttpClient.Wechat.OpenAI.UnitTests/appsettings.json index 1b9b5236..6836cff5 100644 --- a/test/SKIT.FlurlHttpClient.Wechat.OpenAI.UnitTests/appsettings.json +++ b/test/SKIT.FlurlHttpClient.Wechat.OpenAI.UnitTests/appsettings.json @@ -1,5 +1,5 @@ { - "WechatConfig": { + "TestConfig": { "ClientId": "请在此填写用于测试的微信智能对话 ClientId", "ClientKey": "请在此填写用于测试的微信智能对话 ClientKey", "AppId": "请在此填写用于测试的微信智能对话 AppId", diff --git a/test/SKIT.FlurlHttpClient.Wechat.TenpayV3.UnitTests/TestConfigs.cs b/test/SKIT.FlurlHttpClient.Wechat.TenpayV3.UnitTests/TestConfigs.cs index ccad0a67..e368d604 100644 --- a/test/SKIT.FlurlHttpClient.Wechat.TenpayV3.UnitTests/TestConfigs.cs +++ b/test/SKIT.FlurlHttpClient.Wechat.TenpayV3.UnitTests/TestConfigs.cs @@ -16,7 +16,7 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV3.UnitTests using var stream = File.OpenRead("appsettings.local.json"); using var jdoc = JsonDocument.Parse(stream); - var config = jdoc.RootElement.GetProperty("WechatConfig"); + var config = jdoc.RootElement.GetProperty("TestConfig"); WechatAppId = config.GetProperty("AppId").GetString(); WechatMerchantId = config.GetProperty("MerchantId").GetString(); WechatMerchantSecret = config.GetProperty("MerchantSecret").GetString(); @@ -29,7 +29,7 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV3.UnitTests } catch (Exception ex) { - throw new Exception("加载配置文件 appsettings.local.json 失败", ex); + throw new Exception("加载配置文件 appsettings.local.json 失败,请查看 `InnerException` 了解具体失败原因", ex); } } diff --git a/test/SKIT.FlurlHttpClient.Wechat.TenpayV3.UnitTests/appsettings.json b/test/SKIT.FlurlHttpClient.Wechat.TenpayV3.UnitTests/appsettings.json index 55c55e8e..1753a6d8 100644 --- a/test/SKIT.FlurlHttpClient.Wechat.TenpayV3.UnitTests/appsettings.json +++ b/test/SKIT.FlurlHttpClient.Wechat.TenpayV3.UnitTests/appsettings.json @@ -1,5 +1,5 @@ { - "WechatConfig": { + "TestConfig": { "AppId": "请在此填写用于测试的微信 AppId", "MerchantId": "请在此填写用于测试的微信商户号", "MerchantSecret": "请在此填写用于测试的微信商户 API v3 密钥", diff --git a/test/SKIT.FlurlHttpClient.Wechat.Work.UnitTests/TestConfigs.cs b/test/SKIT.FlurlHttpClient.Wechat.Work.UnitTests/TestConfigs.cs index 57db564f..720744f9 100644 --- a/test/SKIT.FlurlHttpClient.Wechat.Work.UnitTests/TestConfigs.cs +++ b/test/SKIT.FlurlHttpClient.Wechat.Work.UnitTests/TestConfigs.cs @@ -16,7 +16,7 @@ namespace SKIT.FlurlHttpClient.Wechat.Work.UnitTests using var stream = File.OpenRead("appsettings.local.json"); using var jdoc = JsonDocument.Parse(stream); - var config = jdoc.RootElement.GetProperty("WechatConfig"); + var config = jdoc.RootElement.GetProperty("TestConfig"); WechatCorpId = config.GetProperty("CorpId").GetString(); WechatAgentId = int.Parse(config.GetProperty("AgentId").GetString()); WechatAgentSecret = config.GetProperty("AgentSecret").GetString(); @@ -26,7 +26,7 @@ namespace SKIT.FlurlHttpClient.Wechat.Work.UnitTests } catch (Exception ex) { - throw new Exception("加载配置文件 appsettings.local.json 失败", ex); + throw new Exception("加载配置文件 appsettings.local.json 失败,请查看 `InnerException` 了解具体失败原因", ex); } } diff --git a/test/SKIT.FlurlHttpClient.Wechat.Work.UnitTests/appsettings.json b/test/SKIT.FlurlHttpClient.Wechat.Work.UnitTests/appsettings.json index c33f1807..f097e314 100644 --- a/test/SKIT.FlurlHttpClient.Wechat.Work.UnitTests/appsettings.json +++ b/test/SKIT.FlurlHttpClient.Wechat.Work.UnitTests/appsettings.json @@ -1,5 +1,5 @@ { - "WechatConfig": { + "TestConfig": { "CorpId": "请在此填写用于测试的企业微信 CorpId", "AgentId": "请在此填写用于测试的企业微信 AgentId", "AgentSecret": "请在此填写用于测试的企业微信 AgentSecret"