|
|
@ -24,7 +24,7 @@ import kotlin.test.assertTrue
|
|
|
|
class ListToMapMigrationTest {
|
|
|
|
class ListToMapMigrationTest {
|
|
|
|
|
|
|
|
|
|
|
|
@Test
|
|
|
|
@Test
|
|
|
|
fun ListToMapMigration_should_migrate_topic_ids() = runTest {
|
|
|
|
fun listToMapMigration_should_migrate_topic_ids() = runTest {
|
|
|
|
// Set up existing preferences with topic ids
|
|
|
|
// Set up existing preferences with topic ids
|
|
|
|
val preMigrationUserPreferences = userPreferences {
|
|
|
|
val preMigrationUserPreferences = userPreferences {
|
|
|
|
deprecatedFollowedTopicIds.addAll(listOf("1", "2", "3"))
|
|
|
|
deprecatedFollowedTopicIds.addAll(listOf("1", "2", "3"))
|
|
|
@ -50,7 +50,7 @@ class ListToMapMigrationTest {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
@Test
|
|
|
|
@Test
|
|
|
|
fun ListToMapMigration_should_migrate_author_ids() = runTest {
|
|
|
|
fun listToMapMigration_should_migrate_author_ids() = runTest {
|
|
|
|
// Set up existing preferences with author ids
|
|
|
|
// Set up existing preferences with author ids
|
|
|
|
val preMigrationUserPreferences = userPreferences {
|
|
|
|
val preMigrationUserPreferences = userPreferences {
|
|
|
|
deprecatedFollowedAuthorIds.addAll(listOf("4", "5", "6"))
|
|
|
|
deprecatedFollowedAuthorIds.addAll(listOf("4", "5", "6"))
|
|
|
@ -76,7 +76,7 @@ class ListToMapMigrationTest {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
@Test
|
|
|
|
@Test
|
|
|
|
fun ListToMapMigration_should_migrate_bookmarks() = runTest {
|
|
|
|
fun listToMapMigration_should_migrate_bookmarks() = runTest {
|
|
|
|
// Set up existing preferences with bookmarks
|
|
|
|
// Set up existing preferences with bookmarks
|
|
|
|
val preMigrationUserPreferences = userPreferences {
|
|
|
|
val preMigrationUserPreferences = userPreferences {
|
|
|
|
deprecatedBookmarkedNewsResourceIds.addAll(listOf("7", "8", "9"))
|
|
|
|
deprecatedBookmarkedNewsResourceIds.addAll(listOf("7", "8", "9"))
|
|
|
|