You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: stream-chat-android-ui-common/src/main/kotlin/io/getstream/chat/android/ui/common/images/StreamImageLoaderFactory.kt
Copy file name to clipboardExpand all lines: stream-chat-android-ui-common/src/test/kotlin/io/getstream/chat/android/ui/common/images/StreamImageLoaderFactoryTest.kt
+13Lines changed: 13 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -23,6 +23,8 @@ import coil3.disk.DiskCache
23
23
importcoil3.gif.AnimatedImageDecoder
24
24
importcoil3.gif.GifDecoder
25
25
importcoil3.memory.MemoryCache
26
+
importcoil3.network.NetworkFetcher
27
+
importcoil3.serviceLoaderEnabled
26
28
importcoil3.video.VideoFrameDecoder
27
29
importokio.Path.Companion.toOkioPath
28
30
importorg.amshove.kluent.internal.assertEquals
@@ -103,6 +105,17 @@ internal class StreamImageLoaderFactoryTest {
103
105
assertTrue(hasVideoDecoder)
104
106
}
105
107
108
+
@Test
109
+
fun`newImageLoader registers network fetcher explicitly without relying on ServiceLoader`() {
110
+
val sut =StreamImageLoaderFactory(builder = { serviceLoaderEnabled(false) })
111
+
112
+
val imageLoader = sut.newImageLoader(context)
113
+
114
+
val hasNetworkFetcher = imageLoader.components.fetcherFactories
0 commit comments