|
|
|
@ -7,9 +7,9 @@ namespace Tiobon.Core.Tests.Common_Test |
|
|
|
|
{ |
|
|
|
|
|
|
|
|
|
[Fact] |
|
|
|
|
public void Get_Async_Test() |
|
|
|
|
public async void Get_Async_Test() |
|
|
|
|
{ |
|
|
|
|
var responseString = HttpHelper.GetAsync("http://apk.neters.club/api/Tiobon").Result; |
|
|
|
|
var responseString = (await HttpHelper.GetAsync("http://apk.neters.club/api/Tiobon")); |
|
|
|
|
|
|
|
|
|
Assert.NotNull(responseString); |
|
|
|
|
} |
|
|
|
@ -17,7 +17,7 @@ namespace Tiobon.Core.Tests.Common_Test |
|
|
|
|
[Fact] |
|
|
|
|
public void Post_Async_Test() |
|
|
|
|
{ |
|
|
|
|
var responseString = HttpHelper.PostAsync("http://apk.neters.club/api/Login/swgLogin", "{\"name\":\"admin\",\"pwd\":\"admin\"}").Result; |
|
|
|
|
var responseString = HttpHelper.PostAsync("http://apk.neters.club/api/Login/swgLogin", "{\"name\":\"admin\",\"pwd\":\"admin\"}"); |
|
|
|
|
|
|
|
|
|
Assert.NotNull(responseString); |
|
|
|
|
} |
|
|
|
|