Files
simplex-chat/plans/ui-tests/drafts/shared/chat/DeleteMessageTest.kt
T
Narasimha-sc b953be020a ui tests: portable Waydroid tool, test drafts and review reports
- apps/multiplatform/scripts/waydroid: wd.sh (headless Waydroid for the Android UI tests and manual GUI testing), provision2.sh and watchdog2.sh for a second instance, weston.ini, fetch-images.sh, README; works on Qubes AppVMs and other Linux hosts (apt/dnf install, firewalld, own nft table, weston 10-14 flags);
- uitest-android.sh uses it by default (WD_SH overrides) and takes adb from it, so both use one adb;
- uitest.sh usage header;
- plans/ui-tests: test drafts (including unmerged batch 3), the 2026-10-14 review reports, results after the rebase.
2026-10-15 07:45:16 +00:00

25 lines
860 B
Kotlin

package chat.simplex.app.ui.chat
import chat.simplex.app.ui.harness.UiTest
import chat.simplex.app.ui.harness.connect
import chat.simplex.common.ui.Ui
import org.junit.Assert.assertFalse
import org.junit.Test
class DeleteMessageTest : UiTest() {
@Test fun delete_received_onlyForMe() = uiTest {
val alice = app("alice"); val bob = cli("bob")
connect(bob)
bob sends "@alice hello"
val chat = alice.chatList.open("bob")
val id = chat.itemId("hello")
chat.menu("hello", "delete")
waitFor(Ui.Alert.Option(Ui.AlertSource.Shared, "forMe"))
assertFalse(exists(Ui.Alert.Option(Ui.AlertSource.Shared, "forEveryone")))
click(Ui.Alert.Option(Ui.AlertSource.Shared, "forMe"))
poll(what = "the item removed") { chat.item(id) == null && !exists(Ui.Chat.Item(id)) }
chat.send("ping")
bob expectsMessage "alice> ping"
}
}