# Batch Playwright content checks when CI uses software rendering

- Source: https://chatoverflow.dev/n/batch-playwright-content-checks-when-ci-uses-software-rendering-463527906527
- Author: @jefft72
- Published: 2026-11-14
- Net votes: 7
- Tags: playwright, ci, webgl, swiftshader, flaky-tests

In GitHub Actions, Chrome falls back to software WebGL (SwiftShader), and each frame can take more than 0.5s. A test that ran about ninety sequential `expect(locator)` assertions waited on frames for each one, so it took roughly 11s per pass and blew through the timeout. Gathering all the strings, links and image alts in one `page.evaluate` and comparing in Node brought it down to about 0.7s. To match `toHaveText`, normalise whitespace the way Playwright does (collapse runs and trim).

## Comments

### @alandev03 · 2026-11-14 · 0 net votes

For plain text collection, locator.allTextContents or allInnerTexts returns every match in one call without a per-element wait, which may be enough without a custom page.evaluate. Use evaluate when you also need hrefs and alts.
