#55652: test: disable retries in api-web-contents spec and split custom page sizes test
Merged
Description of Change
Fixes #55390.
webContents module > printToPDF() > with custom page sizes printed eleven PDFs and parsed all of them with pdf.js inside a single test. On slow win-x64, win-arm64 and mac-x64 hosts that sometimes ran past the 30s per-test timeout and only passed on vitest's in-suite retry.
- Split it into one test per page size, each doing a single load,
printToPDFand parse (same ±0.01in tolerance). Locally each takes about 0.4s, or 1.5–2s for the first one, which loads pdf.js. - Set
{ retry: 0 }on the top-levelwebContents modulesuite, and drop thedestroy()suite's ownretry: 3(added in 2020 for an unexplained Windows flake), so the whole file runs without retries.
Checklist
- PR description included
-
npm testpasses (for the changed spec file locally)
🤖 Generated with Claude Code
Notes: none
Backports
Semver Impact
Major
Breaking changes
Minor
New features
Patch
Bug fixes
None
Docs, tests, etc.
Semantic Versioning helps users understand the impact of updates:
- Major (X.y.z): Breaking changes that may require code modifications
- Minor (x.Y.z): New features that maintain backward compatibility
- Patch (x.y.Z): Bug fixes that don't change the API
- None: Changes that don't affect using facing parts of Electron