aboutsummaryrefslogtreecommitdiff
path: root/Timeline.Tests/Helpers/AssertionResponseExtensions.cs
diff options
context:
space:
mode:
author杨宇千 <crupest@outlook.com>2019-08-20 23:57:47 +0800
committerGitHub <noreply@github.com>2019-08-20 23:57:47 +0800
commitfd95f9abc017575b13a31dd16ac72ef663e984d6 (patch)
tree3d20f696dd097b86eeba497baf8dc1baf966626c /Timeline.Tests/Helpers/AssertionResponseExtensions.cs
parent7814ed7059f74cfecfa8a0c9aa4f9946d1015364 (diff)
parent55f3870cc5301477a7462748f0232f04040a8d2f (diff)
downloadtimeline-fd95f9abc017575b13a31dd16ac72ef663e984d6.tar.gz
timeline-fd95f9abc017575b13a31dd16ac72ef663e984d6.tar.bz2
timeline-fd95f9abc017575b13a31dd16ac72ef663e984d6.zip
Merge pull request #47 from crupest/avatar-enhance
Use etag for avatar cache.
Diffstat (limited to 'Timeline.Tests/Helpers/AssertionResponseExtensions.cs')
-rw-r--r--Timeline.Tests/Helpers/AssertionResponseExtensions.cs3
1 files changed, 2 insertions, 1 deletions
diff --git a/Timeline.Tests/Helpers/AssertionResponseExtensions.cs b/Timeline.Tests/Helpers/AssertionResponseExtensions.cs
index 38617b92..e67a172a 100644
--- a/Timeline.Tests/Helpers/AssertionResponseExtensions.cs
+++ b/Timeline.Tests/Helpers/AssertionResponseExtensions.cs
@@ -23,7 +23,8 @@ namespace Timeline.Tests.Helpers
string padding = new string('\t', context.Depth);
var res = (HttpResponseMessage)value;
- return $"{newline}{padding} Status Code: {res.StatusCode} ; Body: {res.Content.ReadAsStringAsync().Result} ;";
+ var body = res.Content.ReadAsStringAsync().Result;
+ return $"{newline}{padding} Status Code: {res.StatusCode} ; Body: {body.Substring(0, Math.Min(body.Length, 20))} ;";
}
}