Skip to content

test(ui): split cron select coverage - #127020

Closed
steipete wants to merge 1 commit into
mainfrom
codex/ci-split-cron-view-test
Closed

steipete wants to merge 1 commit into
mainfrom
codex/ci-split-cron-view-test

Conversation

@steipete

Copy link
Copy Markdown
Contributor

What Problem This Solves

Fresh pull requests fail check-lint-core-5 because ui/src/pages/cron/view.test.ts exceeds the enforced 1,000-line test limit. This currently blocks otherwise unrelated PRs, including #127013.

Why This Change Was Made

The select rendering tests already form an independent behavior boundary. Moving that existing describe block into view.selects.test.ts brings the original suite below the limit without adding a suppression, changing assertions, or weakening lint policy.

User Impact

No runtime behavior changes. Fresh PR CI can pass the core lint stripe again.

Evidence

  • Before: exact CI command failed with ui/src/pages/cron/view.test.ts:1124:4 File has too many lines (1004).
  • After: node --import tsx scripts/run-oxlint-shards.mts --only=core --split-core --core-stripe=5/5 --threads=1 — 0 warnings, 0 errors across 4,718 files.
  • vitest ... view.test.ts view.selects.test.ts — 42 passed with the same test inventory.
  • oxfmt --check and git diff --check — passed.
  • Autoreview 0.99 and TruffleHog — clean.

Authored by @steipete with Amp.

@clawsweeper

clawsweeper Bot commented Aug 21, 2026

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

@steipete
steipete marked this pull request as ready for review August 21, 2026 04:54
@openclaw-barnacle openclaw-barnacle Bot added app: web-ui App: web-ui size: S maintainer Maintainer-authored PR labels Aug 21, 2026
@steipete

Copy link
Copy Markdown
Contributor Author

Heads up on a collision: I hit the same red check-lint-core-5 from a parallel session and opened #127018 against the same file before seeing this. Both are valid fixes for the same breakage, so one of us should stand down rather than race the merge gate.

Your proof is the stronger of the two on the point that matters most — you ran the exact CI shard command (run-oxlint-shards.mts --only=core --split-core --core-stripe=5/5) and showed 0 errors across 4,718 files, where I only linted the cron directory and relied on hosted CI for the shard.

The difference is headroom. This PR moves cron view selects (~45 lines), which lands view.test.ts just under the 1000 code-line cap — the file was at 1004 and it has gained 20 lines across the last three PRs that touched it (1104 → 1116 → 1124), so it would be back at the cap within a couple of changes. #127018 moves cron view editor instead, which is ~709 lines and the actual reason the file is oversized; view.test.ts ends at 373 lines and view.editor.test.ts at 721.

Both keep test parity (42 tests, 41 it( declarations) and neither adds a suppression.

Unless you object, I'll land #127018 and close this one as superseded. If you'd rather land yours, say so and I'll close mine instead — the important thing is that main goes green, not whose PR does it.

Copy link
Copy Markdown
Contributor Author

Agreed. #127018 has materially better headroom while preserving the same test inventory, and its exact-head CI is green. I’ll stand this duplicate down once #127018 lands so we do not race the merge gate.

@steipete

Copy link
Copy Markdown
Contributor Author

Closing as superseded by #127018, which landed as da18d2f335e — main is green on check-lint-core-5 again.

To restate the reasoning from my earlier comment so the record is complete: both PRs were valid fixes for the same breakage, and this one had the better direct proof (you ran the exact CI shard command; I relied on hosted CI plus a directory-scoped oxlint). The deciding factor was headroom. Moving the ~45-line selects block landed view.test.ts just under the 1000 code-line cap, and that file had gained 20 lines across the three PRs preceding the failure (1104 → 1116 → 1124), so it would have gone red again shortly. #127018 moved the ~709-line editor block instead, leaving view.test.ts at 373 lines and view.editor.test.ts at 721.

Nothing here was wrong — it was a genuine race between two sessions that both hit the same red gate. If the selects block is worth its own file on its own merits rather than as a size fix, that stands as a separate change; view.test.ts has plenty of room for it now either way.

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

Labels

app: web-ui App: web-ui maintainer Maintainer-authored PR size: S

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants