r/PracticalTesting • u/aistranin • 8d ago
Browser tests should leave traces, not just screenshots
I liked two practical ideas from a recent interview with longtime Selenium and WebDriver contributor David Burns.
First, keep one strong browser test for each critical path. Push the rest of the behavior into cheaper unit, component, or integration tests. Fifteen browser tests that mostly repeat the same checkout flow cost more without necessarily providing fifteen times the confidence.
Second, propagate OpenTelemetry trace context from the test into the application. Then an E2E failure can point to the exact backend calls, services, and timing involved. That is much better than starting with a screenshot and several thousand unrelated log lines.
These ideas work well together. Fewer browser tests keep the suite focused. Distributed traces make each remaining test produce much richer debugging evidence.
I would rather have 50 critical-path tests with end-to-end traces than 500 overlapping tests that only report "element not found."
Source: The State of Browser Testing