test: LibreOffice, the layout lint and a monkey read the editor's work back

lo-fuzz.test.ts hands every fuzz seed to LibreOffice as .odt and .docx and
compares what comes back, listing the differences LibreOffice makes by design.
test:layout opens the corpus, the showcase and fuzz seeds in the browser, holds
the page count against LibreOffice and checks the lines for overlap, margin
escapes and stranded headings. test:monkey types at random on corpus documents
and asserts the schema, undo to the start, redo, and that both saved formats
read back. browser.mjs now carries the dev server and the settle helper.
This commit is contained in:
Steffen Becker committed 2026-09-06 19:07:16 +02:00
1 parent 3b6cb06e6f
commit d156482a3f
14 files changed
+874 -177

No files matched your search

+9 -2
View File
@@ -29,10 +29,11 @@ jobs:
# (the lo-roundtrip job below runs that leg).
- run: npm test
# The re-save-through-LibreOffice leg, which self-skips everywhere soffice is absent.
# The LibreOffice legs (self-skipping everywhere soffice is absent) and the layout run,
# which holds the editor's page counts against LibreOffice's PDFs in Chromium.
lo-roundtrip:
runs-on: ubuntu-latest
timeout-minutes: 20
timeout-minutes: 40
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
@@ -43,6 +44,8 @@ jobs:
- run: sudo apt-get update && sudo apt-get install -y --no-install-recommends libreoffice-writer fonts-liberation poppler-utils
- run: npm ci
- run: npm run test:lo
- run: npx playwright-core install --with-deps chromium
- run: npm run test:layout
# Production build booted in the three engines behind the supported browsers
# (vite build.target). WebKit runs on macOS: its text shaping there is Safari's.
@@ -69,3 +72,7 @@ jobs:
- run: npm run build
- run: npm run test:smoke
- run: npm run test:dom
# xmllint validates the files the monkey saves (macOS ships it).
- if: runner.os == 'Linux'
run: sudo apt-get install -y --no-install-recommends libxml2-utils
- run: npm run test:monkey