X-Git-Url: https://git.pterodactylus.net/?p=Sone.git;a=blobdiff_plain;f=src%2Ftest%2Fkotlin%2Fnet%2Fpterodactylus%2Fsone%2Fweb%2Fajax%2FDeletePostAjaxPageTest.kt;h=a57e66d03aa4ef4db69c98b731cc87f7509dc61f;hp=026b71710684169da7bfdce0fb08d154210ae623;hb=0e8c877c57ccdd7d8d7f7f3c80d373ac0b5c3714;hpb=e845284d2f10cf6b0b405966d48938ef1fea0a38 diff --git a/src/test/kotlin/net/pterodactylus/sone/web/ajax/DeletePostAjaxPageTest.kt b/src/test/kotlin/net/pterodactylus/sone/web/ajax/DeletePostAjaxPageTest.kt index 026b717..a57e66d 100644 --- a/src/test/kotlin/net/pterodactylus/sone/web/ajax/DeletePostAjaxPageTest.kt +++ b/src/test/kotlin/net/pterodactylus/sone/web/ajax/DeletePostAjaxPageTest.kt @@ -25,7 +25,7 @@ class DeletePostAjaxPageTest : JsonPageTest("deletePost.ajax", pageSupplier = :: val post = mock() val sone = mock() whenever(post.sone).thenReturn(sone) - addPost("post-id", post) + addPost(post, "post-id") addRequestParameter("post", "post-id") assertThat(json.isSuccess, equalTo(false)) assertThat(json.error, equalTo("not-authorized")) @@ -36,7 +36,7 @@ class DeletePostAjaxPageTest : JsonPageTest("deletePost.ajax", pageSupplier = :: val post = mock() val sone = mock().apply { whenever(isLocal).thenReturn(true) } whenever(post.sone).thenReturn(sone) - addPost("post-id", post) + addPost(post, "post-id") addRequestParameter("post", "post-id") assertThat(json.isSuccess, equalTo(true)) verify(core).deletePost(post)