1 package net.pterodactylus.sone.text
3 import net.pterodactylus.sone.data.Profile
4 import net.pterodactylus.sone.data.Sone
5 import net.pterodactylus.sone.test.mock
6 import org.hamcrest.MatcherAssert.assertThat
7 import org.hamcrest.Matchers.`is`
9 import org.mockito.Mockito.`when`
12 * Unit test for [SonePart].
16 private val sone = mock<Sone>()
19 `when`(sone.profile).thenReturn(mock())
20 `when`(sone.name).thenReturn("sone")
23 private val part = SonePart(sone)
26 fun textIsConstructedFromSonesNiceName() {
27 assertThat<String>(part.text, `is`<String>("sone"))