fix(settle): compare post-action trees in one view across every route

Merged
TH
2d ago
+527-72

Summary

Switching full and interactive snapshots produced false removals. One presentation rule covers settle, verification and snapshot diffs, including depth, scope, raw and custom actions.

Both settle routes select a baseline through capture-kit and reproduce its view. --verify reproduces its pre-action view; combined verification preserves known surface transitions. diff snapshot starts a baseline when the latest stored view differs. Missing presentation metadata means the default full tree.

18 files; includes verify/diff routes and tests. Fixes #4486.

Validation

Head 5b2c4cd685, pristine base efe6bb9eec. Independent findings fixed; seven new regression cases fail before these revisions and pass now. Focused: 962 passed; related integration: 406 passed; full unit: 19,726 passed, three skipped. Standalone smoke: 76 passed, six skipped.

check:affected --run --head HEAD receipt: failed, exactCommit=true (CLI smoke cleanup timeout). Base and head standalone smoke pass; cause unproven. CI must validate the full head.

Live Pixel 9a profile, Android 17/API 37, Settings Device name dialog; T3-bound command, source daemons, android-helper version 0.21.38-dev:

Same command sequenceBaseHead
snapshot -i; snapshot; press @e3 --settle+0 -10+0 -0, 16 unchanged
snapshot -i; wait text "Device name"; scroll down --settle+0 -10+0 -0, 6 unchanged
snapshot; diff snapshot -i19 removalsbaseline initialized, zero removals
snapshot -i; press @e1 --settle --verifyunchanged, falseunchanged, false

Sessions closed; emulator shut down. No live iOS run.