Skip to content

Type into a text box in one call, not one key press per character (BL-16799) - #8294

Merged
hatton merged 2 commits into
masterfrom
BL-16799-type-in-one-call
Sep 3, 2026
Merged

Type into a text box in one call, not one key press per character (BL-16799)#8294
hatton merged 2 commits into
masterfrom
BL-16799-type-in-one-call

Conversation

@hatton

@hatton hatton commented Sep 3, 2026

Copy link
Copy Markdown
Member

typeInGroup pressed a key per character, so the cost of typing grew with the
length of the text, and every test that fills a book paid it. It now clicks in,
selects all, deletes, and inserts the whole string with keyboard.insertText.
CKEditor and Bloom's own markup code both work from the input event that
raises, so the text arrives the same way, and the toHaveText check after it
still proves so.

The AUTOMATION-DEBT.md entry "Filling a text box directly leaves part of the
old text behind" stays open for the half that is not fixed: clearing a box
still needs Control+A and Delete, because neither fill() nor setting the value
leaves CKEditor in a state Bloom saves correctly.

Adds the entry "Typing in a text box raises no key events", for what this
trades away: insertText raises input and nothing else, so no test that types
covers the parts of Bloom that listen for a particular key, and the assertion
cannot tell the difference. A test whose subject is a key press needs a helper
of its own.

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-vite-port. 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

typeInGroup pressed a key per character, so the cost of typing grew with the
length of the text, and every test that fills a book paid it. It now clicks in,
selects all, deletes, and inserts the whole string with keyboard.insertText.
CKEditor and Bloom's own markup code both work from the input event that
raises, so the text arrives the same way, and the toHaveText check after it
still proves so.

The AUTOMATION-DEBT.md entry "Filling a text box directly leaves part of the
old text behind" stays open for the half that is not fixed: clearing a box
still needs Control+A and Delete, because neither fill() nor setting the value
leaves CKEditor in a state Bloom saves correctly.

Adds the entry "Typing in a text box raises no key events", for what this
trades away: insertText raises input and nothing else, so no test that types
covers the parts of Bloom that listen for a particular key, and the assertion
cannot tell the difference. A test whose subject is a key press needs a helper
of its own.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@hatton
hatton force-pushed the BL-16799-type-in-one-call branch from e511353 to de840e5 Compare September 3, 2026 19:40
Master moved while this stack was open, so each branch merges the one below it.
The conflicts were all in src/BloomE2E/AUTOMATION-DEBT.md, in the table of this
stack and in the entries this branch pays off: master gave the table a
pull-request column and annotated each promise with its number, while this branch
deletes its own row and replaces its own promise with what it did. The merge
keeps master table, without this branch row, and this branch own text.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01BaWw4EHWrbFF2fNJvMJVC8
@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 59aaa4d1a80d58b63bf32dd7493cccbd26ec102e.

Base automatically changed from BL-16799-vite-port to master September 3, 2026 23:01
@hatton
hatton merged commit 38f2584 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