projects
/
Sone.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
🎨 Add helper for simulating first start
[Sone.git]
/
src
/
test
/
kotlin
/
net
/
pterodactylus
/
sone
/
web
/
notification
/
NewRemotePostHandlerTest.kt
diff --git
a/src/test/kotlin/net/pterodactylus/sone/web/notification/NewRemotePostHandlerTest.kt
b/src/test/kotlin/net/pterodactylus/sone/web/notification/NewRemotePostHandlerTest.kt
index
5e4e5fc
..
a0d7bc6
100644
(file)
--- a/
src/test/kotlin/net/pterodactylus/sone/web/notification/NewRemotePostHandlerTest.kt
+++ b/
src/test/kotlin/net/pterodactylus/sone/web/notification/NewRemotePostHandlerTest.kt
@@
-27,7
+27,6
@@
import net.pterodactylus.util.notify.*
import net.pterodactylus.util.template.*
import org.hamcrest.MatcherAssert.*
import org.hamcrest.Matchers.*
import net.pterodactylus.util.template.*
import org.hamcrest.MatcherAssert.*
import org.hamcrest.Matchers.*
-import java.io.*
import kotlin.test.*
/**
import kotlin.test.*
/**
@@
-71,9
+70,7
@@
class NewRemotePostHandlerTest {
@Test
fun `handler does not add notification to notification manager during first start`() {
@Test
fun `handler does not add notification to notification manager during first start`() {
- notificationManager.addNotification(object : AbstractNotification("first-start-notification") {
- override fun render(writer: Writer?) = Unit
- })
+ notificationManager.firstStart()
eventBus.post(NewPostFoundEvent(remotePost))
assertThat(notificationManager.notifications, not(hasItem(notification)))
}
eventBus.post(NewPostFoundEvent(remotePost))
assertThat(notificationManager.notifications, not(hasItem(notification)))
}