aboutsummaryrefslogtreecommitdiff
path: root/Timeline.Tests/Helpers/InvalidModelTestHelpers.cs
diff options
context:
space:
mode:
author杨宇千 <crupest@outlook.com>2019-10-19 17:33:38 +0800
committer杨宇千 <crupest@outlook.com>2019-10-19 17:33:38 +0800
commit2984abc9aa0429380459e5b5b6fda2d20058041b (patch)
treef75fde126094e8310dd9e2588bb9b9e8baa79a3b /Timeline.Tests/Helpers/InvalidModelTestHelpers.cs
parentdef8e8dd78812c019a0d6e8e5a3e2de4e82ae3e4 (diff)
downloadtimeline-2984abc9aa0429380459e5b5b6fda2d20058041b.tar.gz
timeline-2984abc9aa0429380459e5b5b6fda2d20058041b.tar.bz2
timeline-2984abc9aa0429380459e5b5b6fda2d20058041b.zip
...
Diffstat (limited to 'Timeline.Tests/Helpers/InvalidModelTestHelpers.cs')
-rw-r--r--Timeline.Tests/Helpers/InvalidModelTestHelpers.cs22
1 files changed, 0 insertions, 22 deletions
diff --git a/Timeline.Tests/Helpers/InvalidModelTestHelpers.cs b/Timeline.Tests/Helpers/InvalidModelTestHelpers.cs
deleted file mode 100644
index 4a445ca4..00000000
--- a/Timeline.Tests/Helpers/InvalidModelTestHelpers.cs
+++ /dev/null
@@ -1,22 +0,0 @@
-using System.Net.Http;
-using System.Threading.Tasks;
-
-namespace Timeline.Tests.Helpers
-{
- public static class InvalidModelTestHelpers
- {
- public static async Task TestPostInvalidModel<T>(HttpClient client, string url, T body)
- {
- var response = await client.PostAsJsonAsync(url, body);
- response.Should().HaveStatusCodeBadRequest()
- .And.Should().HaveBodyAsCommonResponseWithCode(ErrorCodes.Http.Common.InvalidModel);
- }
-
- public static async Task TestPutInvalidModel<T>(HttpClient client, string url, T body)
- {
- var response = await client.PutAsJsonAsync(url, body);
- response.Should().HaveStatusCodeBadRequest()
- .And.Should().HaveBodyAsCommonResponseWithCode(ErrorCodes.Http.Common.InvalidModel);
- }
- }
-}