val currentSone = mock<Sone>()
val template = mock<Template>()
val webInterface = deepMock<WebInterface>()
val currentSone = mock<Sone>()
val template = mock<Template>()
val webInterface = deepMock<WebInterface>()
val eventBus = mock<EventBus>()
val preferences = Preferences(eventBus)
val l10n = webInterface.l10n!!
val eventBus = mock<EventBus>()
val preferences = Preferences(eventBus)
val l10n = webInterface.l10n!!
whenever(core.preferences).thenReturn(preferences)
whenever(core.identityManager.allOwnIdentities).then { ownIdentities }
whenever(core.sones).then { allSones.values }
whenever(core.preferences).thenReturn(preferences)
whenever(core.identityManager.allOwnIdentities).then { ownIdentities }
whenever(core.sones).then { allSones.values }
whenever(core.localSones).then { localSones.values }
whenever(core.getLocalSone(anyString())).then { localSones[it[0]] }
whenever(core.localSones).then { localSones.values }
whenever(core.getLocalSone(anyString())).then { localSones[it[0]] }
- whenever(core.getPost(anyString())).then { allPosts[it[0]].asOptional() }
- whenever(core.getPostReply(anyString())).then { allPostReplies[it[0]].asOptional() }
+ whenever(core.getPost(anyString())).then { allPosts[it[0]] }
+ whenever(core.getPostReply(anyString())).then { allPostReplies[it[0]] }
whenever(core.getReplies(anyString())).then { perPostReplies[it[0]].asList() }
whenever(core.getAlbum(anyString())).then { allAlbums[it[0]] }
whenever(core.getImage(anyString())).then { allImages[it[0]]}
whenever(core.getReplies(anyString())).then { perPostReplies[it[0]].asList() }
whenever(core.getAlbum(anyString())).then { allAlbums[it[0]] }
whenever(core.getImage(anyString())).then { allImages[it[0]]}