Skip to content

Let an e2e run test the working tree's front end (BL-16799) - #8293

Merged
hatton merged 2 commits into
masterfrom
BL-16799-vite-port
Sep 3, 2026
Merged

Let an e2e run test the working tree's front end (BL-16799)#8293
hatton merged 2 commits into
masterfrom
BL-16799-vite-port

Conversation

@hatton

@hatton hatton commented Sep 3, 2026

Copy link
Copy Markdown
Member

A launched Bloom serves its React UI from the built output/browser, so an edit
to a .tsx file did not reach the suite until somebody rebuilt that bundle,
which AGENTS.md reserves for a developer or CI.

Set BLOOM_E2E_VITE_PORT= and fixtures/launchBloom.ts passes --vite-port
to the Bloom it launches, which then loads every React control from that dev
server. Bloom already had the option; nothing passed it.

Use 5173 and set the variable. The README, the add-e2e-test skill and the new
AUTOMATION-DEBT.md entry all say why: the page list and the toolbox write
http://localhost:5173 into their own imports, so on any other port those two
frames come up empty, which reads as the feature being missing; and an unset
variable does not mean "no dev server", because a dev build probes 5173 by
itself, so a run can quietly test a bundle from yesterday.

Adds two AUTOMATION-DEBT.md entries rather than retiring one: "Which front end
the e2e suite tests depends on what else is running", for the choice the
fixture still does not own, and "A Vite dev server only reaches the whole UI on
port 5173", for the two pug files that ignore the port.

Verified: type check clean. A full suite run against a dev server on the
working tree is what found both entries above.

This is one of eleven stacked pull requests (BL-16799)

Each one pays down one entry of src/BloomE2E/AUTOMATION-DEBT.md, and each branches off the one before it. Base: BL-16799-component-tests-in-ci. Review only this pull request's own commit; the ones below it are reviewed in their own pull requests. The first six change test and tooling code only; the last five also change product code.

  1. BL-16799-automation-scripts — Make the bloom-automation scripts safe to ask for help
  2. BL-16799-vr-collect-failures — Report every failed image comparison in a visual-regression case, not the first
  3. BL-16799-component-tests-in-ci — Run the component-tester Playwright suites nightly
  4. BL-16799-vite-port — Let an e2e run test the working tree's front end
  5. BL-16799-type-in-one-call — Type into a text box in one call, not one key press per character
  6. BL-16799-page-screenshot — Capture a whole book page from a test
  7. BL-16799-toolbox-registration — Register the toolbox tools from one list both callers share
  8. BL-16799-shell-document — Stop a test attaching to a shell document Bloom does not drive
  9. BL-16799-tab-test-ids — Click a workspace tab by a test id, not by its localized label
  10. BL-16799-page-change — Refuse a page change the Edit tab cannot do, and wait before asking
  11. BL-16799-collection-languages — Set a collection's languages through an e2e hook, not by writing XML

Replaces #8276, which did all of this in one pull request.

Verification of the whole stack, at its tip: the C# suite passes (3338 passed, 13 skipped), the front-end vitest suite passes (781 passed, 5 skipped), and the src/BloomE2E suite passes against a Vite dev server on the working tree (36 passed, 0 skipped, 8.2 minutes). Each pull request also has its own type check and lint.

🤖 Generated with Claude Code

Devin review


This change is Reviewable

Comment thread src/BloomE2E/fixtures/launchBloom.ts
A launched Bloom serves its React UI from the built output/browser, so an edit
to a .tsx file did not reach the suite until somebody rebuilt that bundle,
which AGENTS.md reserves for a developer or CI.

Set BLOOM_E2E_VITE_PORT=<n> and fixtures/launchBloom.ts passes --vite-port <n>
to the Bloom it launches, which then loads every React control from that dev
server. Bloom already had the option; nothing passed it.

Use 5173 and set the variable. The README, the add-e2e-test skill and the new
AUTOMATION-DEBT.md entry all say why: the page list and the toolbox write
http://localhost:5173 into their own imports, so on any other port those two
frames come up empty, which reads as the feature being missing; and an unset
variable does not mean "no dev server", because a dev build probes 5173 by
itself, so a run can quietly test a bundle from yesterday.

getViteDevPort rejects a value that is not a whole number from 1 to 65535,
naming the variable and the value it holds. Passed through untouched, a typo
reaches Bloom as --vite-port, and Bloom's ValidateStartupVitePort then stops
with a dialog no test can dismiss: every test in the run waits out its launch
timeout and reports that Bloom never came up, and nothing in that report names
the variable.

Adds two AUTOMATION-DEBT.md entries rather than retiring one: "Which front end
the e2e suite tests depends on what else is running", for the choice the
fixture still does not own, and "A Vite dev server only reaches the whole UI on
port 5173", for the two pug files that ignore the port.

Verified: type check clean. A full suite run against a dev server on the
working tree is what found both entries above.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@hatton
hatton force-pushed the BL-16799-vite-port branch from aadbeb2 to c4fce04 Compare September 3, 2026 19:40
Only src/BloomE2E/AUTOMATION-DEBT.md conflicted, in two places, and both sides
of each belong.

Master reworked the table of this stack to give each pull request its number
and to name two branches that are not open yet. This branch deletes its own
row, so the merge takes master's table without it.

Both sides also add text at one spot. Master adds a "being fixed" paragraph to
the entry about uploading under a developer's own account; this branch adds the
new entry about which front end a run tests. The paragraph stays with the entry
it is about, so it comes first, and the new entry follows it.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01BaWw4EHWrbFF2fNJvMJVC8
Base automatically changed from BL-16799-component-tests-in-ci to master September 3, 2026 22:28
@hatton

hatton commented Sep 3, 2026

Copy link
Copy Markdown
Member Author

[Claude Opus 5 from Hatton's machine during devin-review]

Consulted Devin on 2026-09-03 22:45 UTC up to commit 215d8123d70179961e58e153d416474048ffb713.

@hatton
hatton merged commit b39db1f into master Sep 3, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant