Post

1/ End-to-end tests are supposed to give you confidence. Instead, many Playwright setups create… chaos. Here’s why (and what to do instead) 🧵

3/ Signs your Playwright setup is failing • Flaky tests due to shared state or data interference • Failures on retries because of leftover state • Tests wasting time on repetitive UI setup • Symptoms reappearing unexpectedly

0 reposts0 likes

4/ The core problem: too much setup in the UI. If half your suite is just logging in, preparing users, etc., you’re doing it wrong.

5/ The alternative: API-driven test data Create your users, subscriptions, and test state via API instead of the UI. Use fixtures to inject that data into Playwright.

6/ This approach lets your tests focus on behavior, not scaffolding. It leads to faster suites, easier maintainability, and more confidence.

7/ Use shared fixtures. If external dependencies fail (e.g. a third-party API), it should be handled at the fixture level — not in every single test.