Skip to content

test(e2e): add editor smoke tests for typing, formulas and slides#197

Open
juliusknorr wants to merge 1 commit into
mainfrom
test/e2e-editor-smoke-tests
Open

test(e2e): add editor smoke tests for typing, formulas and slides#197
juliusknorr wants to merge 1 commit into
mainfrom
test/e2e-editor-smoke-tests

Conversation

@juliusknorr

Copy link
Copy Markdown
Member

Summary

Adds Playwright smoke tests exercising basic editing in each editor, run against the example app:

  • Document — type text, apply bold/italic, verify the text round-trips via the automation API
  • Spreadsheet — enter numbers and a =A1+A2 formula, verify the formula is accepted in the cell
  • Presentation — build a three-slide deck and verify the slide count

A shared helpers.ts opens a new document from the example page, waits for the editor iframe to finish loading, and exposes editorApi() to call window.Asc.editor inside the iframe.

Notes

  • Element ids are renamed in this build, so tests drive the editors via keyboard shortcuts and the asc_* automation API rather than clicking toolbar buttons.
  • Spreadsheet test asserts the formula is accepted, not that it computes 15: asc_getCellInfo().asc_getText() returns the formula string and GetSelectedText() is empty for cell selections. A TODO documents the clipboard-based computed-value check (needs clipboard permissions in the project config).
  • Presentation slides are added through AddSlide() because Ctrl+M only fires when the thumbnail panel is focused.

Testing

Verified locally against a running example server:

3 passed (11.7s)

AI assistance

Tests authored with AI assistance (Claude Code, claude-opus-4-8); reviewed and verified by the contributor.

Add Playwright smoke tests covering basic editing in each editor:
- document: type text, apply bold/italic, verify text round-trips
- spreadsheet: enter numbers and a formula, verify it is accepted
- presentation: build a three-slide deck

Shared helpers open a new document from the example app and reach the
editor automation API inside the iframe.

Assisted-by: ClaudeCode:claude-opus-4-8
Signed-off-by: Julius Knorr <jus@bitgrid.net>
@juliusknorr juliusknorr requested review from a team, chrip and moodyjmz and removed request for a team June 16, 2026 20:36
@juliusknorr juliusknorr moved this from 📄 To do to 🏗️ In progress in 📄 Euro-Office team Jun 16, 2026
@juliusknorr juliusknorr self-assigned this Jun 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

Status: 🏗️ In progress

Development

Successfully merging this pull request may close these issues.

1 participant