X-Git-Url: https://git.pterodactylus.net/?p=Sone.git;a=blobdiff_plain;f=src%2Ftest%2Fkotlin%2Fnet%2Fpterodactylus%2Fsone%2Fweb%2Fpages%2FSearchPageTest.kt;h=2da2b24925ce98cc5a39658de3f872a92d50cb78;hp=b0aee649456bbcd8a9d7660fac15675096a34918;hb=03c29a3838e23ed0b9731ca4d84cf58038c30dfe;hpb=25727046bb4fd452ed0fb8511dee73786b0b738a diff --git a/src/test/kotlin/net/pterodactylus/sone/web/pages/SearchPageTest.kt b/src/test/kotlin/net/pterodactylus/sone/web/pages/SearchPageTest.kt index b0aee64..2da2b24 100644 --- a/src/test/kotlin/net/pterodactylus/sone/web/pages/SearchPageTest.kt +++ b/src/test/kotlin/net/pterodactylus/sone/web/pages/SearchPageTest.kt @@ -73,21 +73,21 @@ class SearchPageTest: WebPageTest({ template, webInterface -> SearchPage(templat @Test fun `searching for sone link without prefix redirects to view sone page`() { - addSone("sone-id", mock()) + addSone("sone-id", mock()) addHttpRequestParameter("query", "sone-id") verifyRedirect("viewSone.html?sone=sone-id") } @Test fun `searching for a post link redirects to post page`() { - addPost("Post-id", mock()) + addPost("Post-id", mock()) addHttpRequestParameter("query", "post://Post-id") verifyRedirect("viewPost.html?post=Post-id") } @Test fun `searching for a post ID without prefix redirects to post page`() { - addPost("post-id", mock()) + addPost("post-id", mock()) addHttpRequestParameter("query", "post-id") verifyRedirect("viewPost.html?post=post-id") } @@ -110,28 +110,28 @@ class SearchPageTest: WebPageTest({ template, webInterface -> SearchPage(templat @Test fun `searching for an album link redirects to the image browser`() { - addAlbum("album-id", mock()) + addAlbum("album-id", mock()) addHttpRequestParameter("query", "album://album-id") verifyRedirect("imageBrowser.html?album=album-id") } @Test fun `searching for an album ID redirects to the image browser`() { - addAlbum("album-id", mock()) + addAlbum("album-id", mock()) addHttpRequestParameter("query", "album-id") verifyRedirect("imageBrowser.html?album=album-id") } @Test fun `searching for an image link redirects to the image browser`() { - addImage("image-id", mock()) + addImage("image-id", mock()) addHttpRequestParameter("query", "image://image-id") verifyRedirect("imageBrowser.html?image=image-id") } @Test fun `searching for an image ID redirects to the image browser`() { - addImage("image-id", mock()) + addImage("image-id", mock()) addHttpRequestParameter("query", "image-id") verifyRedirect("imageBrowser.html?image=image-id") }