Skip to content

D-1186: De-flake device tests, sync cassini-ux pin, hygiene - #267

Merged
silviot merged 4 commits into
mainfrom
participate/d-1186
Nov 27, 2026
Merged

silviot merged 4 commits into
mainfrom
participate/d-1186

Conversation

@silviot

@silviot silviot commented Nov 27, 2026

Copy link
Copy Markdown
Member

Seat: local-claude
Participate: auto
Fixes D-1186

Summary

Consolidation pass, one commit per checklist item. Nothing user-facing changes.

  • De-flake BulkTransferDeviceTest. The failure was anEmptyLibraryCannotOpenTheZipDestinationPicker on API 34, in run 45877137395, attempt 1. Its logcat semantics dump shows the Library with the first-run top bar and no Settings screen, so the Settings tap was lost. Cause: createAndroidComposeRule launches MainActivity before @Before runs Background.reset(), and the Library opens loading with the search bar's Settings button. When the catalogue turns out empty, FirstRunTopBar replaces that bar, and its Settings button is a new node. The test can find the old button and click it while it is being disposed. The new Flows.awaitLibraryTopBar() waits for the bar that matches the stored catalogue: the first-run bar when it is empty, otherwise the first-run bar must be gone (the loading bar and the loaded bar are then the same node). BulkTransferDeviceTest.openSettings uses it, and so does AppAccessibilityTest, which taps Settings right after launch too. Audit (D88): androidTest has no Thread.sleep or SystemClock.sleep. The one delay(16) runs on a virtual StandardTestDispatcher (UiEventsTest).
  • Sync the cassini-ux pin of the bundle and the wave5/ catalog: from 160fb92 to main e709094 (includes D113). The catalog bytes now equal the 60ac93d copies that phase2/ and d112/ already pin, so all four catalog copies come from one revision again. Every generated resource changes only its Generated from cassini-ux … header; no string changes. LIBRARY-RULES.md, HARMONY.md and library-vectors/expected/main.json pick up D112/D113. The separately pinned inputs (import types, head-start vectors, round-trip vectors) are unchanged. The D113 Mac copy is not in the shared catalog yet (D113 §6), so there is nothing to generate for it. test_wave5_strings now compares against the bundle commit instead of a hard-coded SHA.
  • Dead code. I removed two unused getters, DownloadSpeed.kilobytesPerSecond and RecorderQueueCounts.hasWork. A cross-module scan of the D-1161…D-1180 wave found no other unused declarations or resources (tests/ci/test_unused_resources.py passes). I left the CassiniSpacing design tokens, which mirror docs/design/ui.md §4.4. I did not shrink the detekt baseline (about 1.6k entries, almost all formatting), because autocorrecting it would touch many unrelated files and the verbatim engine code.
  • Docs. In CONTRIBUTING, the macOS/Windows "tests without the pixel comparison" command was detached from its sentence and lacked :app-logic:test; it is now in place and complete. The local checks now list tests/ci and the checks of the cassini-ux pinned inputs. I checked the README module layout against settings.gradle.kts, and it matches.

Review focus

  • Whether awaitLibraryTopBar's use of waitGone in the non-empty case is right. The loading state has hero == null, so it never shows the first-run bar.
  • The vendored diff is large (strings.json ×3) but byte-identical to cassini-ux e709094. scripts/check-ux-pin.py verifies every SHA-256.

Checked bug classes

Walk review/BUG-CLASSES.md (classes 1–19):

🤖 Generated with Claude Code

silviot and others added 4 commits November 27, 2026 12:28
The bundle and the wave5 catalog move from 160fb92 to cassini-ux main. The
catalog bytes now equal the 60ac93d phase2/d112 copies, so every generated
resource changes only its source-commit header; LIBRARY-RULES, HARMONY and
the library vectors pick up D112/D113.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
…ice tests (D-1186)

The rule launches MainActivity before @before resets the data, and the Library
opens loading with the search bar. When the catalogue turns out empty the
first-run bar replaces it with a new Settings node, so a tap on the old one
was lost (BulkTransferDeviceTest.anEmptyLibraryCannotOpenTheZipDestinationPicker
on API 34, run 45877137395 attempt 1: the Library with the first-run bar, no
Settings). Flows.awaitLibraryTopBar waits for the bar of the stored catalogue;
BulkTransferDeviceTest and AppAccessibilityTest use it before the tap.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
…s.hasWork (D-1186)

Neither getter has a reader in main or test sources since the D-1161-D-1180
wave; no behaviour changes.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
…non-Linux test command (D-1186)

The command for running the unit tests without the pixel comparison sat after
the goldens download, detached from its sentence, and lacked :app-logic:test.
The local checks now include tests/ci and the pinned-input checks CI runs.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@silviot
silviot marked this pull request as ready for review November 27, 2026 11:50
@silviot silviot added the full-ci Run all four Android emulator API levels on this PR label Nov 27, 2026
@silviot
silviot merged commit 0d12555 into main Nov 27, 2026
27 of 29 checks passed
@silviot
silviot deleted the participate/d-1186 branch November 27, 2026 12:23
@silviot

silviot commented Nov 27, 2026

Copy link
Copy Markdown
Member Author

Pipeline: cassini-android #267 is merged (review: ship). Continue with your next item.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

full-ci Run all four Android emulator API levels on this PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant