@ -20,15 +20,14 @@ import com.google.samples.apps.nowinandroid.core.domain.GetFollowableTopicsStrea
import com.google.samples.apps.nowinandroid.core.domain.GetSortedFollowableAuthorsStreamUseCase
import com.google.samples.apps.nowinandroid.core.domain.model.FollowableAuthor
import com.google.samples.apps.nowinandroid.core.domain.model.FollowableTopic
import com.google.samples.apps.nowinandroid.core.model.data. nextF akeAuthor
import com.google.samples.apps.nowinandroid.core.model.data. nextF akeTopic
import com.google.samples.apps.nowinandroid.core.model.data. f akeAuthor
import com.google.samples.apps.nowinandroid.core.model.data. f akeTopic
import com.google.samples.apps.nowinandroid.core.testing.repository.TestAuthorsRepository
import com.google.samples.apps.nowinandroid.core.testing.repository.TestTopicsRepository
import com.google.samples.apps.nowinandroid.core.testing.repository.TestUserDataRepository
import com.google.samples.apps.nowinandroid.core.testing.util.MainDispatcherRule
import com.google.samples.apps.nowinandroid.feature.interests.InterestsUiState
import com.google.samples.apps.nowinandroid.feature.interests.InterestsViewModel
import kotlin.random.Random
import kotlin.test.assertEquals
import kotlinx.coroutines.flow.collect
import kotlinx.coroutines.launch
@ -206,25 +205,25 @@ class InterestsViewModelTest {
}
private val testInputAuthors = listOf (
FollowableAuthor ( author = Random . nextF akeAuthor( id = " 1 " ) , isFollowed = true ) ,
FollowableAuthor ( author = Random . nextF akeAuthor( id = " 2 " ) , isFollowed = false ) ,
FollowableAuthor ( author = Random . nextF akeAuthor( id = " 3 " ) , isFollowed = false ) ,
FollowableAuthor ( author = f akeAuthor( id = " 1 " ) , isFollowed = true ) ,
FollowableAuthor ( author = f akeAuthor( id = " 2 " ) , isFollowed = false ) ,
FollowableAuthor ( author = f akeAuthor( id = " 3 " ) , isFollowed = false ) ,
)
private val testOutputAuthors = listOf (
FollowableAuthor ( author = Random . nextF akeAuthor( id = " 1 " ) , isFollowed = true ) ,
FollowableAuthor ( author = Random . nextF akeAuthor( id = " 2 " ) , isFollowed = true ) ,
FollowableAuthor ( author = Random . nextF akeAuthor( id = " 3 " ) , isFollowed = false ) ,
FollowableAuthor ( author = f akeAuthor( id = " 1 " ) , isFollowed = true ) ,
FollowableAuthor ( author = f akeAuthor( id = " 2 " ) , isFollowed = true ) ,
FollowableAuthor ( author = f akeAuthor( id = " 3 " ) , isFollowed = false ) ,
)
private val testInputTopics = listOf (
FollowableTopic ( Random . nextF akeTopic( id = " 1 " ) , isFollowed = true ) ,
FollowableTopic ( Random . nextF akeTopic( id = " 2 " ) , isFollowed = false ) ,
FollowableTopic ( Random . nextF akeTopic( id = " 3 " ) , isFollowed = false ) ,
FollowableTopic ( f akeTopic( id = " 1 " ) , isFollowed = true ) ,
FollowableTopic ( f akeTopic( id = " 2 " ) , isFollowed = false ) ,
FollowableTopic ( f akeTopic( id = " 3 " ) , isFollowed = false ) ,
)
private val testOutputTopics = listOf (
FollowableTopic ( Random . nextF akeTopic( id = " 1 " ) , isFollowed = true ) ,
FollowableTopic ( Random . nextF akeTopic( id = " 2 " ) , isFollowed = true ) ,
FollowableTopic ( Random . nextF akeTopic( id = " 3 " ) , isFollowed = false ) ,
FollowableTopic ( f akeTopic( id = " 1 " ) , isFollowed = true ) ,
FollowableTopic ( f akeTopic( id = " 2 " ) , isFollowed = true ) ,
FollowableTopic ( f akeTopic( id = " 3 " ) , isFollowed = false ) ,
)