package com.cottondb.days import android.app.Application import androidx.compose.runtime.getValue import androidx.compose.runtime.mutableStateOf import androidx.compose.runtime.setValue import androidx.compose.ui.test.assertTextEquals import androidx.compose.ui.test.junit4.createComposeRule import androidx.compose.ui.test.onNodeWithTag import com.cottondb.days.ui.SettingsSaid import org.junit.Rule import org.junit.Test import org.junit.runner.RunWith import org.robolectric.RobolectricTestRunner import org.robolectric.annotation.Config /** * What was just said on Days' settings, as the emulator showed it wrong (21 Nov 2026): Sync now said nothing there (its * "Syncing…" went to the list's foot, under the page). It stands at the foot of every settings page. (The account on * the page is now the shell's SettingsHome, asked again on every change and after every act: DaysSettingsTest.) */ @RunWith(RobolectricTestRunner::class) @Config(sdk = [35], qualifiers = "w400dp-h800dp-mdpi", application = Application::class) class DaysSettingsAccountTest { @get:Rule val compose = createComposeRule() @Test fun what_was_just_said_stands_on_the_page() { var said by mutableStateOf(null) compose.setContent { SettingsSaid(said) } compose.onNodeWithTag("days-settings-said").assertDoesNotExist() compose.runOnIdle { said = "Syncing…" } compose.onNodeWithTag("days-settings-said").assertTextEquals("Syncing…") } }