test(e2e): capture scenario assertion failure evidence - #2368
Open
billsbooth wants to merge 1 commit into
Open
Conversation
Member
|
The change looks good at 6ef99b0: scenario assertions now reuse failure capture before cleanup, preserve the original error, and avoid capturing command failures twice. The deterministic regressions cover those boundaries. CI remains the blocker: iOS failed in the alert XCTest before fixture E2E, and Android failed at automation-press. Neither run verifies the new scenario-assertion capture path; confirm the uploaded screenshot and snapshot on a deliberate assertion failure when that lane can run. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Capture failure artifacts when a live scenario assertion fails outside a CLI step. The iOS long-press search exhausted allowed probes, then threw without preserving the failed screen or accessibility tree.
Scope
Two files: shared live-scenario harness and its deterministic tests. Capture before caller teardown, preserve the original exception, avoid duplicate capture for already-reported command failures, and leave successful scenarios unchanged. No gesture, driver, timeout, recovery or product behavior change.
Validation
At
6ef99b084,pnpm check:affected --runpasses all runnable gates: format, lint, types, Fallow and 101 Node integration cases (9 native skips). Six new cases cover allowed misses, pre-command assertions, duplicate suppression, unavailable capture, artifact I/O failure and success; three failed before implementation. CI pending. This does not fix the original iOS visibility failure.Verification
iOS failure contains four unsuccessful visibility probes and cleanup, but its uploaded fixture artifacts lack failure screenshot/snapshot. Source confirms only unexpected command failures previously invoked collection. The new tests assert original-error identity, owned-session flags, artifact output and coverage bookkeeping.
Automated Test Plan
Run
node scripts/node-test-tmpdir.ts --test test/integration/live-device-e2e-runtime.test.ts test/integration/live-device-e2e-failed-step-evidence.test.ts. All ten tests must pass with no device or account. Automatic native fixture lanes remain selected: on any scenario assertion, inspect failure report and capture artifacts before session cleanup; successful runs must create no failure captures. No production data, funds or external delivery required.