X-Git-Url: https://git.pterodactylus.net/?p=Sone.git;a=blobdiff_plain;f=src%2Ftest%2Fkotlin%2Fnet%2Fpterodactylus%2Fsone%2Ffcp%2FDeleteReplyCommandTest.kt;h=013b1c1a676aec7e2b6d8d2f70dbfa36cfaf27cb;hp=57c4c3039e0924af6bcd42837ee18454f38ede77;hb=c088dd5a2896d777cc30c5676583782bfa923729;hpb=7522c3e795b53134beadd21c2e72fe48500bde6a diff --git a/src/test/kotlin/net/pterodactylus/sone/fcp/DeleteReplyCommandTest.kt b/src/test/kotlin/net/pterodactylus/sone/fcp/DeleteReplyCommandTest.kt index 57c4c30..013b1c1 100644 --- a/src/test/kotlin/net/pterodactylus/sone/fcp/DeleteReplyCommandTest.kt +++ b/src/test/kotlin/net/pterodactylus/sone/fcp/DeleteReplyCommandTest.kt @@ -32,13 +32,13 @@ class DeleteReplyCommandTest : SoneCommandTest() { @Test fun `request with invalid post reply parameter results in fcp exception`() { - parameters.putSingle("Reply", "InvalidReplyId") + parameters += "Reply" to "InvalidReplyId" executeCommandAndExpectFcpException() } @Test fun `request with remote post reply parameter results in error response`() { - parameters.putSingle("Reply", "RemoteReplyId") + parameters += "Reply" to "RemoteReplyId" whenever(core.getPostReply("RemoteReplyId")).thenReturn(of(remotePostReply)) val response = command.execute(parameters) assertThat(response.replyParameters["Message"], equalTo("Error")) @@ -47,7 +47,7 @@ class DeleteReplyCommandTest : SoneCommandTest() { @Test fun `request with local post reply parameter deletes reply`() { - parameters.putSingle("Reply", "RemoteReplyId") + parameters += "Reply" to "RemoteReplyId" whenever(core.getPostReply("RemoteReplyId")).thenReturn(of(localPostReply)) val response = command.execute(parameters) assertThat(response.replyParameters["Message"], equalTo("ReplyDeleted"))