Skip to content

Check the playing player without waiting for the screen to go idle - #26

Merged
silviot merged 1 commit into
mainfrom
acceptance-walk-live-player
Oct 31, 2026
Merged

silviot merged 1 commit into
mainfrom
acceptance-walk-live-player

Conversation

@DrMeyers

@DrMeyers DrMeyers commented Oct 31, 2026 •

Copy link
Copy Markdown

Summary

The acceptance walk (AcceptanceWalkTest, @Manual, scripts/acceptance-walk.sh) stopped at screen 03, Read & listen, with Not shown: ContentDescription = 'Pause'. So it never reached Settings, and the README/store screenshots can't be refreshed (coordination R2).

Cause. Since 4b5d0cf (#16) the playing word is highlighted every frame, so the player redraws every frame while it plays. Compose test lookups (onAllNodes(...).fetchSemanticsNodes()) first wait for the UI to go idle. The wait for the Pause button therefore returned only after the 15 s clip had ended, when the button said Play again. Logcat of CI run 41160257011: playback ran from 02:40:07.5 to 02:40:21.2 (680,640 frames, the whole clip), the test saw playing in the graph state, and the tree printed on timeout shows Play / Paused. App behaviour isn't affected; CI's device checks don't run the walk, which is why nobody noticed.

Fix. Flows.liveNodes reads the semantics nodes of the activity's Compose roots (ViewRootForTest.semanticsOwner) on the UI thread as they are now. Flows.waitShownLive polls it inside waitUntil, which advances frames but doesn't wait for idle. The walk uses them for the Pause button and the highlighted-word check. Its other checks run while nothing plays and keep the idle-synced lookups.

Checks

  • ./gradlew detekt :app:compileDebugAndroidTestKotlin passes (macOS). No app or :ui code changes, so no goldens.
  • The walk on a device: run 41161555538 (CI emulator, API 34, Pixel 5 profile, real models; this commit plus a temporary workflow that isn't in the PR). realModels reports OK (1 test) in light and dark, with all 13 screens per theme (03 Read & listen through 10). Before the fix it stopped at 03 in both themes.
    • The script's last check then reported "The model files changed". The before/after listings have the same files, names, byte sizes and verified checksums. Only the block total of files/speaker-models grew by 4 KB (130436 → 130440): the models were pushed seconds before the walk, and that's the filesystem finishing its allocation. With models installed long before, as the script expects, this doesn't happen.
  • CI run 41161568772: all jobs green.
  • Signed-off-by: not added (a personal certification for the maintainer).

🤖 Generated with Claude Code

Since the playing word is highlighted every frame (4b5d0cf), the player
redraws every frame while it plays. A Compose test lookup first waits
for the UI to go idle, so the acceptance walk's wait for the Pause
button returned only after the 15 s clip had ended, when the button
said Play again: "Not shown: ContentDescription = 'Pause'". The walk
never reached its later screens.

Flows.liveNodes reads the semantics nodes of the activity's Compose
roots on the UI thread as they are now, and waitShownLive polls it
inside waitUntil, which advances frames but does not wait for idle. The
walk uses them for the Pause button and the highlighted word; its other
checks run while nothing plays and keep the idle-synced lookups.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
DrMeyers pushed a commit that referenced this pull request Oct 31, 2026
The About card of the README and store Settings screenshots reads
"Cassini talk 0.3.0". Taken with the acceptance walk (light and dark,
real models) on a CI emulator: API 34, Pixel 5 profile, the 1080 x 2340
of the earlier screenshots (run 41161555538, with the walk fix of #26),
then 540 px wide with Pillow and optipng -o5 -strip all as
docs/development.md says (run 41162612753).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@silviot
silviot merged commit 3b83a49 into main Oct 31, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants