Repository navigation
fix(run): keep --last-failed reruns honest: failure-limit skips, carried debts, kept evidence - #724
Conversation
🟢 e2e web: 90 passedAll 90 tests in 41 files
e2e 0.16.0 · 1m 49s · web · run artifacts |
🟢 e2e web agent: 32 passed33 agent steps · 25 replayed from cache · 20 model calls · 76.4k tokens (91% cached) · $0.0037 All 32 tests in 5 files
e2e 0.16.0 · 2m 45s · web · run artifacts |
🟢 e2e android agent: 20 passed24 agent steps · 124 model calls · 727.8k tokens (84% cached) · $0.0449 All 20 tests in 1 file
e2e 0.16.0 · 9m 15s · android-emulator · run artifacts |
🟢 e2e android: 54 passed, 1 skippedAll 55 tests in 7 files
e2e 0.16.0 · 7m 38s · android-emulator · run artifacts |
🟢 e2e ios: 2 flaky, 50 passed, 1 skipped
|
| Test | Time | |
|---|---|---|
| tests/controls.e2e.ts · 1 flaky, 22 passed, 1 skipped | 3m 31s | |
| 🟢 | control inventory › a label query resolves a labeled text field | 10.7s |
| 🟢 | control inventory › a labeled field answers name, display value, value reads, fill, and clear | 18.2s |
| 🟢 | control inventory › a placeholder query and attribute reads find the field | 5.7s |
| 🟢 | control inventory › a secure field takes a fill and denies value reads | 10.3s |
| 🟢 | control inventory › press sends a character and Enter through the soft keyboard | 9.5s |
| 🟢 | control inventory › a field autofocuses on mount and focus() moves the focus | 11.0s |
| control inventory › toBeFocused follows the focus (2 failed attempts first) | 16.0s | |
| 🟢 | control inventory › a switch checks, unchecks, and reports its state | 12.5s |
| 🟢 | control inventory › checkbox and radio roles answer getByRole, and a checkbox toggles by tap | 10.0s |
| 🟢 | control inventory › checkbox and radio roles check, uncheck, and report their state | 15.1s |
| 🟢 | control inventory › a radio group reports the checked option | 9.7s |
| 🟢 | control inventory › buttons report disabled, enabled, and a state that arrives later | 8.4s |
| 🟢 | control inventory › a display: none element is absent rather than hidden, its visible twin attached | 8.4s |
| 🟢 | control inventory › a header answers its accessible name | 5.7s |
| 🟢 | control inventory › a tab row answers count, all, texts, filters, positions, and switching | 7.8s |
| 🟢 | control inventory › a list answers counts, list-form text, reads, and boxes in order | 8.6s |
| ⏭️ | control inventory › a row contains its texts (skipped: React Native flattens a plain View out of the accessibility tree on both platforms: XCTest and the Android helper report a View with a testID as a leaf beside its children, so filter({ has }) and a query scoped to it match nothing; only Sc…) | |
| 🟢 | control inventory › a long press lands as one | 9.8s |
| 🟢 | control inventory › pointer verbs land at the point asked for | 11.3s |
| 🟢 | control inventory › an ambiguous locator fails at once | 6.8s |
| 🟢 | control inventory › screenshot, restart, and clearState reopen the app on its home list | 13.9s |
| 🟢 | refusals › verbs a device never declares are refused before the engine | 5ms |
| 🟢 | refusals › keys the soft keyboard cannot send are refused by the engine | 647ms |
| 🟢 | refusals › a missing locator fails as not found once its timeout passes | 1.1s |
| tests/device-fixture.e2e.ts · 1 flaky, 8 passed | 1m 14s | |
| device fixture › setAppearance flips the color scheme the app reads (2 failed attempts first) | 11.9s | |
| 🟢 | device fixture › setOrientation rotates the window the app measures | 6.7s |
| 🟢 | device fixture › the clipboard reads back what was written | 5.9s |
| 🟢 | device fixture › home leaves the app, openApp brings it back where it was | 5.8s |
| 🟢 | device fixture › closeApp then openApp relaunches on the home list | 8.1s |
| 🟢 | device fixture › foregroundApp after closeApp reports the closed session as APP_NOT_OPEN | 5.2s |
| 🟢 | device fixture › device.back pops the scenario | 6.4s |
| 🟢 | device fixture › setLocation and clearLocation change what the app reads | 12.7s |
| 🟢 | device fixture › enrollBiometrics and setBiometrics answer a biometric prompt | 11.3s |
| 🟢 | tests/device.e2e.ts · 2 passed | 57.9s |
| 🟢 | sequential onboarding echoes the exact values | 43.9s |
| 🟢 | onboarding rejects a malformed email before advancing | 13.9s |
| 🟢 | tests/flows-lists.e2e.ts · 7 passed | 3m 56s |
| 🟢 | infinite scroll reaches the target item | 29.2s |
| 🟢 | product catalog adds exactly two of the right variant | 11.5s |
| 🟢 | gestures: long-press, then swipe left | 10.5s |
| 🟢 | sticky chrome: accept below the fold, then continue | 12.9s |
| 🟢 | async states: load, pull to refresh, claim through the toast | 14.0s |
| 🟢 | huge virtualized list reaches row 512 | 2m 23s |
| 🟢 | web view coupon form applies the code shown on the page | 15.6s |
| 🟢 | tests/flows.e2e.ts · 7 passed | 1m 22s |
| 🟢 | text inputs unlock the submit button | 18.3s |
| 🟢 | filled text inputs report their values | 11.3s |
| 🟢 | modal flow confirms through the native alert | 11.4s |
| 🟢 | bottom tabs act inside the last tab | 8.6s |
| 🟢 | error recovery retries, then confirms the delete | 10.6s |
| 🟢 | choice controls place the exact order | 10.0s |
| 🟢 | debounced search selects the target once results arrive | 11.9s |
| 🟢 | tests/login-form.e2e.ts · 3 passed | 52.7s |
| 🟢 | login form › rejects a malformed email | 14.0s |
| 🟢 | login form › rejects an unknown account | 14.5s |
| 🟢 | login form › signs in and logs out | 24.2s |
| 🟢 | tests/smoke.e2e.ts · 1 passed | 13.6s |
| 🟢 | home lists the scenarios and opens one | 13.6s |
e2e 0.16.0 · 6m 57s · ios-simulator · run artifacts
🟢 e2e ios agent: 1 flaky, 20 passed, 1 skipped25 agent steps · 128 model calls · 827.3k tokens (83% cached) · $0.0548
|
| Test | Agent | Time | |
|---|---|---|---|
| tests-agent/scenarios.e2e.ts · 1 flaky, 20 passed, 1 skipped | 25 steps · 128 calls | 12m 49s | |
| 🟢 | act completes Login Form | 1 step · 10 calls | 1m 21s |
| 🟢 | act completes Infinite Scroll List | 1 step · 3 calls | 51.3s |
| 🟢 | act completes Modal Flow | 1 step · 4 calls | 16.3s |
| 🟢 | act completes Bottom Tabs | 1 step · 3 calls | 12.3s |
| 🟢 | act completes Text Input Variations | 1 step · 3 calls | 26.2s |
| 🟢 | act completes Broken Accessibility | 2 steps · 7 calls | 39.0s |
| 🟢 | act completes Vision Only | 2 steps · 6 calls | 33.3s |
| act completes Gestures (1 failed attempt first) | 1 step · 10 calls | 47.9s | |
| 🟢 | act completes Async States | 1 step · 7 calls | 32.0s |
| 🟢 | act completes Debounced Search | 1 step · 4 calls | 18.6s |
| 🟢 | act completes Flattened Registration Form | 2 steps · 10 calls | 1m 14s |
| 🟢 | act completes Flattened Login | 2 steps · 12 calls | 1m 26s |
| 🟢 | act completes Sticky Chrome Target | 1 step · 8 calls | 43.2s |
| 🟢 | act completes WebView Accessibility | 1 step · 5 calls | 30.8s |
| 🟢 | act completes Permission Prompt | 1 step · 3 calls | 19.1s |
| 🟢 | act completes Photo Picker | 1 step · 4 calls | 18.1s |
| 🟢 | act completes Product Catalog | 1 step · 5 calls | 16.0s |
| 🟢 | act completes Error Recovery | 1 step · 6 calls | 19.1s |
| 🟢 | act completes Choice Controls | 1 step · 7 calls | 43.9s |
| 🟢 | act completes Stripe PaymentSheet | 1 step · 7 calls | 39.1s |
| 🟢 | act completes Apple Pay | 1 step · 4 calls | 23.1s |
| ⏭️ | act completes Apple Pay Billing Address (skipped: the CI simulator's Apple Pay sheet skips the billing-address step, so the scenario cannot be completed there) |
e2e 0.16.0 · 13m 36s · ios-simulator · run artifacts
There was a problem hiding this comment.
All reported issues were addressed across 30 files
Heads up: you’re close to your included review allowance. Set a flex budget so reviews don’t pause.
Re-trigger cubic
|
[claude-opus-5-5] responding on behalf of okwasniewski Calls for the owner:
|
okwasniewski
left a comment
There was a problem hiding this comment.
On 9000371:
Can a carried test get dropped when its file fails to collect during a narrowed rerun? notRun in last-run.ts needs collected.has(result.testId), and with a positional the runner moves an unselected file that fails to import into collection.uncollected and keeps going, so none of its tests are in collectedTestIds. Example: B fails, then e2e run --last-failed tests/a.e2e.ts runs while b.e2e.ts has a temporary import error. The rerun only prints the skipped notice, its report carries no row for B, and the next --last-failed and the GitHub fold go green although B never passed. Passing the uncollected files into carryForward and keeping rows from those files carried would close it.
reviewed 9000371 by Hermes on behalf of @okwasniewski
9000371 to
9d82440
Compare
…ied debts, kept evidence --last-failed now reruns tests --max-failures skipped. A test or failed suite hook another filter leaves out stays owed in the report's new run.carried until a rerun runs it; the github fold shows carried rows and errors and stays red while anything is carried. A rerun prunes artifacts/ to what the previous report names and writes its attempts under artifacts/rerun-<n>/ instead of wiping the tree and reusing attempt paths.
The report has no row for an unneeded setup, so carryForward now asks the collection whether a test still exists instead of the report's rows.
…n rerun docs Distinct ids in the carried fixture row.
…, in the folded page
c4b0c69 to
547c6f0
Compare
Partial
--last-failedreruns could go green on tests that never ran, forget a failed hook, and destroy the evidence the GitHub comment links to.failure-limit skips rerun.
failure-limitjoins the undelivered skip causes (packages/e2e/src/run/last-run.ts). Before this,e2e run --max-failures 1 || e2e run --last-failedreran only the failed test and exited 0.Owed tests are carried. A
--last-failedrerun's report gets a new optionalrun.carriedfield (report-v1.schema.json, valid fixture,sdk-types.ts). It holds:--grep,--tag,--target,--agent, or a positional;beforeAll/afterAllfailures in their scope.lastFailedIdsselects carried tests, so a test stays owed across consecutive partial reruns until one runs it. A hook failure resolves once a rerun runs any test in its scope without the hook failing. The rerun's own exit code and summary still count only what it ran.The fold stays red.
foldLastRun(packages/github/src/merge.ts) shows carried rows in place of filtered ones and reads the previous run's carried rows as history. It appends carried hook errors and turns the page red while a carried test or hook failure is owed. A carried test the run before interrupted reached no verdict (fix(report)!: count interrupted tests apart from failures #713), so it leaves the outcome alone and the page reads ⏹️, not red; the next--last-failedstill runs it. Before,...current.rundropped the previous run's errors.Evidence survives. The rerun no longer wipes
artifacts/:pruneArtifacts,reportArtifactPaths);artifacts/rerun-<n>/(claimRerunDir, exclusive mkdir, numbered past any existing) and files its attempts there viarerunDiron the worker bootstrap;attempt-0of the run it folds.A full run still clears everything and keeps the same paths.
Docs:
reference/cli.mdx(--last-failed,--output),reference/config.mdx,reference/reporters.mdx,ci.mdx(the rerun no longer emptiesartifacts/, so one upload covers both steps),github.mdx,debugging.mdx,skills/e2e/references/running.md.Review findings fixed before opening (fresh-context reviewer):
--target/--agentleft no row, so owed tests on unselected targets or agents were dropped. They are now carried while the test is collected and the target still exists.failure-limitskip left the fold green. Now anything carried turns the page red.afterAlldebt was dropped. Existence is now checked against the run's collected test ids (Devin thread).Verified
Ran it locally: yes
/tmp/oskar-fix-rerun-integrity(rebuilt as/tmp/oskar-724-reprofor the rebase) with the real built CLI (node packages/e2e/dist/cli/bin.js). Anapiproject covers D7. Awebproject (trace: 'on',github()reporter, fakedGITHUB_ACTIONSenv writing the job summary) has anafterAllthat throws in A and a fixable B with screenshots.foldLastRun(report, previous). The "fold links" column re-hashes every artifact the folded page links and checks it against the report'ssha256.run --max-failures 1, thenFIX_T1=1 run --last-failed--last-failed --grep T1, then--last-failedNO_TESTSexit 2run.carried, then exit 1 running T2, T3run || FIX_B=1 run --last-failed: fold linksrerun-1/run, thenFIX_B=1 run --last-failed --grep B: job summary🟢 e2e: 1 flaky, 1 passed, HOOK_FAILED lost, A's screenshot and trace gone🔴 e2e: 1 flaky, 1 passed+HOOK_FAILED (afterAll), all 10 links ok--last-failed(hook still broken)NO_TESTS, exit 2FIX_A=1 run --last-failedNO_TESTS, exit 2run, break t2's import,FIX_T1=1 run --last-failed tests/t1.e2e.ts, fix t2,run --last-failedrun.carried, debt lost--last-failedruns T2FIX_T1=1 run --last-failed --grep T1, thenrun --last-failedrun.carriedas interrupted, fold### ⏹️ e2e: 1 interrupted, 1 flaky(status passed, exit 0), next--last-failedruns T4New regression tests:
tests/unit/last-run.test.ts,tests/unit/rerun-artifacts.test.ts, the carried constraints intests/unit/schema-fixtures.test.ts, and githubtests/unit/merge.test.ts;runner-lifecycle.test.ts(the failure limit and a filter carried across reruns, a hook carried until its scope runs, a test of a file a narrowed rerun could not import still carried) andoutput.test.ts(evidence kept byte for byte,rerun-1/, thenrerun-2/, and a full run back at the root).Re-run on the rebase onto main 7f9ee10 (after #713, #741, #727): every row above matches.
The new fold tests fail against main's
merge.ts. Locally green:pnpm check, e2e (unit and integration), github, testbed, web-benchmark.