qa-pdf-print
PDF + print rendering tests: 4 skills (html-to-pdf-regression, pdf-accessibility-checker, pdf-snapshot-tester, print-stylesheet-tests) and 1 agent (pdf-test-author). Covers print/PDF output where qa-visual-regression covers screen output.
Install this plugin
/plugin install qa-pdf-print@testland-qaPart of role bundle: qa-role-frontend
qa-pdf-print
Print + PDF rendering testing - closes the gap left by qa-visual-regression (which covers screen output but not print/PDF). Critical for invoices, contracts, statements, regulatory filings.
Components
| Type | Name | Description |
|---|---|---|
| Skill | pdf-snapshot-tester | Per-page render via pdftocairo / pdf2image; pixel-diff via Pillow / pixelmatch; page-range targeting; font-substitution detection; UPDATE_PDF_BASELINES workflow |
| Skill | print-stylesheet-tests | Playwright emulateMedia({ media: 'print' }) + page.pdf(); @page size + margin tests; printBackground + preferCSSPageSize; page-count regression tests |
| Skill | html-to-pdf-regression | Cross-engine HTML→PDF (Chromium / WeasyPrint / wkhtmltopdf); per-engine baseline; font-embedding verification; engine-version pinning |
| Skill | pdf-accessibility-checker | PDF/UA-1 (ISO 14289) conformance via veraPDF; Tagged PDF + StructTreeRoot + MarkInfo /Marked; Alt text + /Lang + /Title; WCAG 2.1 PDF technique mapping |
| Agent | pdf-test-author | Detects PDF engine (Chromium page.pdf() / WeasyPrint / wkhtmltopdf) from project config and emits one test file per output type; activates pdf-accessibility-checker for tagged PDFs |
Install
/plugin marketplace add testland/qa
/plugin install qa-pdf-print@testland-qaSkills
html-to-pdf-regression
Cross-engine HTML→PDF regression - generate the same source HTML through Chromium `page.pdf()`, WeasyPrint (Python, BSD), and wkhtmltopdf, then compare per-engine outputs page-by-page. Catches engine-specific font embedding bugs, page-break drift, @page rule support gaps. Pair with pdf-snapshot-tester for the per-engine pixel diff.
pdf-accessibility-checker
Test PDF accessibility (PDF/UA conformance) - tagged-PDF structure (StructTreeRoot), alternative text on images (Alt), reading-order, language metadata (Lang), document title, heading hierarchy. Use veraPDF / PAC (PDF Accessibility Checker) / pdfix / Adobe Acrobat Pro headless; map each finding back to WCAG 2.1 PDF Techniques (PDF1 - PDF23).
pdf-snapshot-tester
Test PDF outputs by converting per-page to images (`pdftocairo` / pdf2image / Poppler) and running pixel-diff (pixelmatch / Resemble.js / Pillow `ImageChops`) against approved baselines. Per-page-range targeting, threshold tuning, font-substitution warnings, byte-stable PDF metadata stripping (CreationDate, /ID).
print-stylesheet-tests
Test CSS print-media output via Playwright `page.emulateMedia({ media: ''''print'''' })` + `page.pdf()` - `@page` rule (size, margin, orphans, widows), `@page :first / :left / :right` pseudo-classes, `break-before/after/inside`, `@media print` selector activation, page-break suppression on headings.