🎨 Fix formatting
[Sone.git] / src / test / kotlin / net / pterodactylus / sone / web / pages / ViewSonePageTest.kt
index ee311e2..6e97e36 100644 (file)
@@ -1,29 +1,19 @@
 package net.pterodactylus.sone.web.pages
 
-import net.pterodactylus.sone.data.Post
-import net.pterodactylus.sone.data.PostReply
-import net.pterodactylus.sone.data.Profile
-import net.pterodactylus.sone.data.Sone
-import net.pterodactylus.sone.test.getInstance
-import net.pterodactylus.sone.test.isOnPage
-import net.pterodactylus.sone.test.mock
-import net.pterodactylus.sone.test.whenever
-import net.pterodactylus.sone.utils.Pagination
-import net.pterodactylus.sone.utils.asOptional
-import net.pterodactylus.sone.web.baseInjector
-import org.hamcrest.MatcherAssert.assertThat
-import org.hamcrest.Matchers.contains
-import org.hamcrest.Matchers.equalTo
-import org.hamcrest.Matchers.notNullValue
-import org.hamcrest.Matchers.nullValue
-import org.junit.Before
-import org.junit.Test
+import net.pterodactylus.sone.data.*
+import net.pterodactylus.sone.test.*
+import net.pterodactylus.sone.utils.*
+import net.pterodactylus.sone.web.*
+import net.pterodactylus.sone.web.page.*
+import org.hamcrest.MatcherAssert.*
+import org.hamcrest.Matchers.*
+import org.junit.*
 import java.net.*
 
 /**
  * Unit test for [ViewSonePage].
  */
-class ViewSonePageTest: WebPageTest(::ViewSonePage) {
+class ViewSonePageTest : WebPageTest(::ViewSonePage) {
 
        init {
                whenever(currentSone.id).thenReturn("sone-id")
@@ -210,7 +200,12 @@ class ViewSonePageTest: WebPageTest(::ViewSonePage) {
 
        @Test
        fun `page can be created by dependency injection`() {
-           assertThat(baseInjector.getInstance<ViewSonePage>(), notNullValue())
+               assertThat(baseInjector.getInstance<ViewSonePage>(), notNullValue())
+       }
+
+       @Test
+       fun `page is annotated with correct template path`() {
+               assertThat(page.templatePath, equalTo("/templates/viewSone.html"))
        }
 
 }