diff options
author | crupest <crupest@outlook.com> | 2019-11-20 00:32:32 +0800 |
---|---|---|
committer | crupest <crupest@outlook.com> | 2019-11-20 00:32:32 +0800 |
commit | eb35c608b3d73db2cd819a8280fa1cdce1f59dc2 (patch) | |
tree | 4a390f9c7bd4794fd399002f9b0eca7c7efa673f /Timeline.Tests/IntegratedTests/PersonalTimelineTest.cs | |
parent | a72960e54a89bd31dcb8be8f52e097007dfd23e5 (diff) | |
download | timeline-eb35c608b3d73db2cd819a8280fa1cdce1f59dc2.tar.gz timeline-eb35c608b3d73db2cd819a8280fa1cdce1f59dc2.tar.bz2 timeline-eb35c608b3d73db2cd819a8280fa1cdce1f59dc2.zip |
Add delete nonexist post test, and fix the bug.
Diffstat (limited to 'Timeline.Tests/IntegratedTests/PersonalTimelineTest.cs')
-rw-r--r-- | Timeline.Tests/IntegratedTests/PersonalTimelineTest.cs | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/Timeline.Tests/IntegratedTests/PersonalTimelineTest.cs b/Timeline.Tests/IntegratedTests/PersonalTimelineTest.cs index 9dae4c3e..43549d1a 100644 --- a/Timeline.Tests/IntegratedTests/PersonalTimelineTest.cs +++ b/Timeline.Tests/IntegratedTests/PersonalTimelineTest.cs @@ -442,6 +442,13 @@ namespace Timeline.Tests.IntegratedTests res.Should().HaveStatusCode(200); } { + var res = await client.PostAsJsonAsync("users/user/timeline/postop/delete", + new TimelinePostDeleteRequest { Id = 30000 }); + res.Should().HaveStatusCode(400) + .And.HaveCommonBody() + .Which.Code.Should().Be(ErrorCodes.Http.Timeline.PostOperationDeleteNotExist); + } + { var res = await client.GetAsync("users/user/timeline/posts"); res.Should().HaveStatusCode(200) .And.HaveJsonBody<TimelinePostInfo[]>() |