Performance testing basics
Nobody expects an Automation QA to be a performance engineer, but knowing the terminology and being able to explain QA's role is a middle-level expectation.
The main types of load testing:
- Load test — behaviour under expected load (e.g. 500 concurrent users): does response time meet the SLA?
- Stress test — pushing the system to its breaking point: where and HOW does it break (graceful degradation or total collapse)?
- Spike test — a sudden surge (a marketing campaign, ticket sales opening)
- Soak/endurance test — sustained load over a long period: memory leaks and resource exhaustion surface here
Tools: k6 (scripted in JS — the most natural choice for a JS-fluent QA, easy to wire into CI), JMeter (older, GUI-driven, a wide plugin ecosystem, common in enterprises), Gatling (Scala/Java). These work at the protocol level — thousands of HTTP requests without opening a browser, which is exactly why they scale.
There's a critical distinction here: Playwright is not a load-testing tool. Opening 500 browser instances isn't feasible (each eats hundreds of MB) and it's the wrong model anyway.
Frontend performance is a different field, and QA's role there is more direct. The measures are the Core Web Vitals:
- LCP (Largest Contentful Paint) — when the largest content element appears; the measure of "the page loaded". Good: ≤2.5s
- INP (Interaction to Next Paint) — responsiveness to user interaction (it replaced FID in 2024). Good: ≤200ms
- CLS (Cumulative Layout Shift) — how much the layout jumps while loading; the "I clicked the button and it moved" problem. Good: ≤0.1
Lighthouse CI measures these automatically in the pipeline and lets you set a performance budget: if LCP exceeds 2.5s, the PR is blocked. That moves performance out of the "we'll look at it later" category and into regression control — naturally QA territory.
QA's role (state this clearly in an interview): I'm not a performance engineer, but (1) I make sure performance requirements are stated measurably ("search results at p95 < 1.5s", not "make it fast"); (2) I wire Lighthouse CI into the pipeline and maintain the budget; (3) I notice obvious performance regressions in functional tests (a sudden jump in suite duration is often a signal the product got slower); (4) when serious load testing is needed, I formulate the requirement and work with a performance specialist or team.
| Question | Can a UI test answer it? | The right tool |
|---|---|---|
| How fast does the page load for a single user? | Partially — as an indicative measure | Lighthouse CI (more precise and comparable) |
| Does the system hold at 500 concurrent users? | No | k6 / JMeter — protocol-level load |
| Did LCP regress after the last release? | Partially | Lighthouse CI + a performance budget |
| Is there a memory leak under 24 hours of load? | No | A soak test + server monitoring (APM) |
| Does the UI freeze after a button press? | Yes — a functional test catches this | Playwright (the assertion timeout signals it) |
The most common mistake in interviews: "I measure performance with Playwright, since the test takes 3 seconds." That isn't a measurement — it's an unrepeatable number depending on CI machine load, the network and the number of parallel workers. The correct position: Playwright gives an indicator; the measuring instruments are Lighthouse and k6. Knowing that distinction separates "has heard the terms" from "understands the field".
📚 Sources and documentation
- Web Vitalsofficialweb.dev
- Lighthouseofficialdeveloper.chrome.com