mirror of
https://github.com/openclaw/openclaw.git
synced 2026-09-28 22:15:22 +08:00
test(android): settle fixture transport before history adoption
The fail-fast operator socket can deliver its final disconnect after screenshot history starts, invalidating that fixture-owned history before the voice-note assertion. Join only the fixture transport before composition. Keep the selected gateway, original 1000ms deadline, recording, independent media import and Beta-switch assertions. Deterministic legal ordering fails both original variants and passes with the fix; the uninstrumented class passes all 25 cases. No production or visual UI change or device claim. Co-authored-by: RomneyDa <6581799+RomneyDa@users.noreply.github.com> Co-authored-by: vyctorbrzezowski <51521767+vyctorbrzezowski@users.noreply.github.com> Co-authored-by: steipete <58493+steipete@users.noreply.github.com> Co-authored-by: jalehman <550978+jalehman@users.noreply.github.com>
This commit is contained in:
co-authored by
RomneyDa
vyctorbrzezowski
steipete
jalehman
parent
3d0390e666
commit
44628e7e16
@@ -17,6 +17,7 @@ import ai.openclaw.app.drainWithMainLooper
|
||||
import ai.openclaw.app.gateway.GatewayEndpoint
|
||||
import ai.openclaw.app.gateway.GatewayRegistryEntry
|
||||
import ai.openclaw.app.gateway.GatewayRegistryEntryKind
|
||||
import ai.openclaw.app.gateway.GatewaySession
|
||||
import ai.openclaw.app.ui.chat.ChatScreen
|
||||
import ai.openclaw.app.ui.chat.PendingAttachment
|
||||
import ai.openclaw.app.ui.design.ClawDesignTheme
|
||||
@@ -593,6 +594,11 @@ class SidebarGatewayPickerTest {
|
||||
val alpha = savedGateway("Local QA Alpha")
|
||||
val beta = savedGateway("Local QA Beta")
|
||||
focus(alpha)
|
||||
// Chat uses screenshot RPCs here; the fail-fast socket must not invalidate their history.
|
||||
// Stop only this fixture-owned transport, preserving the selected gateway and composer.
|
||||
drainWithMainLooper {
|
||||
ReflectionHelpers.getField<GatewaySession>(runtime, "operatorSession").disconnectAndJoin()
|
||||
}
|
||||
val lifecycleOwner =
|
||||
object : LifecycleOwner {
|
||||
override val lifecycle = LifecycleRegistry(this)
|
||||
|
||||
Reference in New Issue
Block a user