test: compare the rendered page against LibreOffice
Everything else in tests/ compares documents at the model level; nothing checked what a page actually looks like. run.mjs renders the same file through soffice and through the real app in Chromium, reads both back as word boxes, and diffs page count, line count, line text and line position. The corpus stays out of the repo: make-fixtures.mjs authors the baseline .docx files, and real-world documents are whatever you drop into the gitignored fixtures/ yourself.
This commit is contained in:
1 parent
09f57c5326
commit
361b14dc17
5 files changed
+657
-1
No files matched your search
+3
-1
@@ -17,7 +17,9 @@
|
||||
"check": "svelte-check --tsconfig ./tsconfig.json",
|
||||
"test": "vitest run",
|
||||
"test:watch": "vitest",
|
||||
"test:lo": "vitest run tests/lo-roundtrip.test.ts"
|
||||
"test:lo": "vitest run tests/lo-roundtrip.test.ts",
|
||||
"test:parity": "node tests/render-parity/run.mjs",
|
||||
"test:parity:fixtures": "node tests/render-parity/make-fixtures.mjs"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@sveltejs/vite-plugin-svelte": "^7.1.2",
|
||||
|
||||
Reference in new issue
Block a user