- val notification = notificationManager.notifications.single() as ListNotification<*>
- assertThat(notification.elements, contains<Any>(sone))
- }
-
- @Test
- fun `handler sets correct key for sones`() {
- eventBus.post(NewSoneFoundEvent(sone))
- val notification = notificationManager.notifications.single() as ListNotification<*>
- assertThat(notification.render(), equalTo(listOf(sone).toString()))
- }
-
- @Test
- fun `handler creates non-dismissable notification`() {
- eventBus.post(NewSoneFoundEvent(sone))
- val notification = notificationManager.notifications.single() as ListNotification<*>
- assertThat(notification, matches("is not dismissable") { !it.isDismissable })