aboutsummaryrefslogtreecommitdiff
path: root/Timeline.Tests/Helpers/Authentication/AuthenticationExtensions.cs
diff options
context:
space:
mode:
author杨宇千 <crupest@outlook.com>2019-08-11 16:12:23 +0800
committerGitHub <noreply@github.com>2019-08-11 16:12:23 +0800
commitac072939e727181f79e3d6d1acd7d7ac1f4c29f6 (patch)
tree3e4e7de38b9f0e5832923a6bc1ce7872fc4370a5 /Timeline.Tests/Helpers/Authentication/AuthenticationExtensions.cs
parentd97185e6152a327f6ef3b1873bfd86f1a3aac3a1 (diff)
parent6f4924af35e4620ccf11145e28be9490773155f6 (diff)
downloadtimeline-ac072939e727181f79e3d6d1acd7d7ac1f4c29f6.tar.gz
timeline-ac072939e727181f79e3d6d1acd7d7ac1f4c29f6.tar.bz2
timeline-ac072939e727181f79e3d6d1acd7d7ac1f4c29f6.zip
Merge pull request #39 from crupest/fluent-assertion
Use FluentAssertions.
Diffstat (limited to 'Timeline.Tests/Helpers/Authentication/AuthenticationExtensions.cs')
-rw-r--r--Timeline.Tests/Helpers/Authentication/AuthenticationExtensions.cs2
1 files changed, 1 insertions, 1 deletions
diff --git a/Timeline.Tests/Helpers/Authentication/AuthenticationExtensions.cs b/Timeline.Tests/Helpers/Authentication/AuthenticationExtensions.cs
index 8a44c852..c8a79e58 100644
--- a/Timeline.Tests/Helpers/Authentication/AuthenticationExtensions.cs
+++ b/Timeline.Tests/Helpers/Authentication/AuthenticationExtensions.cs
@@ -14,7 +14,7 @@ namespace Timeline.Tests.Helpers.Authentication
public static async Task<CreateTokenResponse> CreateUserTokenAsync(this HttpClient client, string username, string password, int? expireOffset = null)
{
var response = await client.PostAsJsonAsync(CreateTokenUrl, new CreateTokenRequest { Username = username, Password = password, ExpireOffset = expireOffset });
- response.AssertOk();
+ response.Should().HaveStatusCodeOk();
var result = JsonConvert.DeserializeObject<CreateTokenResponse>(await response.Content.ReadAsStringAsync());
return result;
}