Enable automatic back pagination and unread indicators by default (#7800)

* Enable automatic back pagination and unread indicators by default

We want to test these in the nightlies.
This commit is contained in:
Jorge Martin Espinosa
2026-09-30 15:09:32 +02:00
committed by GitHub
parent e5606e6162
commit 8c0d23771c
2 changed files with 16 additions and 3 deletions
@@ -217,6 +217,10 @@ class RoomListPresenterTest {
val presenter = createRoomListPresenter(client = client)
presenter.test {
val initialState = awaitItem()
// Skip intermediate event for loading the value of the `UnreadIndicatorCount` feature flag
skipItems(1)
val summary = createRoomListRoomSummary()
initialState.eventSink(RoomListEvent.ShowContextMenu(summary))
@@ -260,6 +264,10 @@ class RoomListPresenterTest {
val presenter = createRoomListPresenter(client = client)
presenter.test {
val initialState = awaitItem()
// Skip intermediate event for loading the value of the `UnreadIndicatorCount` feature flag
skipItems(1)
val summary = createRoomListRoomSummary()
initialState.eventSink(RoomListEvent.ShowContextMenu(summary))
@@ -309,6 +317,10 @@ class RoomListPresenterTest {
)
presenter.test {
val initialState = awaitItem()
// Skip intermediate event for loading the value of the `UnreadIndicatorCount` feature flag
skipItems(1)
eventRecorder.assertEmpty()
initialState.eventSink(RoomListEvent.ToggleSearchResults)
eventRecorder.assertSingle(
@@ -398,6 +410,7 @@ class RoomListPresenterTest {
client = matrixClient,
)
presenter.test {
skipItems(1) // Skip initial state
assertThat(awaitItem().contentState).isInstanceOf(RoomListContentState.Empty::class.java)
}
}
@@ -616,7 +629,7 @@ class RoomListPresenterTest {
)
presenter.test {
assertThat(announcementService.announcementsToShowFlow().first()).isEmpty()
skipItems(1)
skipItems(2) // Skip initial state and intermediate event for loading the value of the `UnreadIndicatorCount` feature flag
val state = awaitItem()
assertThat(state.contentAsRooms().showNewNotificationSoundBanner).isFalse()
announcementService.emitAnnouncementsToShow(listOf(Announcement.NewNotificationSound))
@@ -121,14 +121,14 @@ enum class FeatureFlags(
title = "Automatic back pagination of rooms",
description = "Allow the app to automatically back paginate in rooms to pre-fetch older messages in background." +
"\nRequires an app restart to take effect.",
defaultValue = { false },
defaultValue = { true },
isFinished = false,
),
UnreadIndicatorCount(
key = "feature.unread_indicator_count",
title = "Unread indicator count",
description = "Show the number of unread messages on the unread indicator in the room list.",
defaultValue = { false },
defaultValue = { true },
isFinished = false,
),
SendGalleryMessages(