Testing

Why We Advocate for Visual Verification Over Brittle E2E Tests

November 10, 2026

The Sunk Cost of End-to-End Testing

There is a specific kind of engineering fatigue that comes from maintaining a legacy End-to-End test suite. It is the sinking feeling you get when you open a Pull Request, confident in your logic, only to watch the CI pipeline turn red thirty minutes later. You pull the logs, you trace the failure, and you realize the product isn't broken. The business logic is flawless. The database transactions committed perfectly.

The build failed because a designer decided to change a CSS class from `btn-primary` to `button-main`. Or because an AI coding assistant refactored a component to use semantic HTML, nesting a `<span>` inside a `<div>` in a way the test script didn't expect.

The application works perfectly. The user experience is unchanged. But your build is blocked, your velocity is halted, and your team wastes another hour maintaining the tests that were supposed to save them time.

We have spent the last decade managing test code instead of managing product quality.

Tying Quality to Implementation Details

The fundamental flaw of traditional E2E frameworks like Selenium, Cypress, and Playwright is that they force you to tie your quality gates to your implementation details. When you write an assertion that relies on a specific DOM structure, a specific XPath, or even a specific `data-testid`, you are making a contract with the HTML.

But HTML is not the product. HTML is just a delivery mechanism. The user does not care what your DOM looks like. The user cares that when they click the 'Checkout' button, a receipt appears on their screen.

By coupling our tests to the markup, we created a system that punishes us for iterating. If you want to clean up your CSS grid, you have to rewrite your tests. If you want to migrate a legacy component to a new design system, you have to rewrite your tests. Every refactor carries a massive QA tax.

The Vibe Coding Catalyst

This problem was annoying five years ago. Today, with the rise of AI-assisted 'vibe coding,' it is an existential threat to engineering velocity. AI agents do not respect your legacy DOM structures. They rewrite entire pages in seconds. They optimize components in ways that completely obliterate traditional testing selectors.

If your testing strategy relies on the DOM remaining stable, AI will destroy your test suite overnight. You cannot pair 10x code generation with a QA process that breaks every time the code changes.

Testing at the Speed of Thought

This is why we advocate for Visual Verification. It is not just a different testing tool; it is a fundamental shift in testing philosophy. Visual verification completely decouples assertions from the DOM. It treats the application exactly the way a human treats the application: by looking at the rendered pixels.

When you shift to a visual pipeline, you stop asking, 'Does this DOM node exist?' You start asking, 'Can the user see the checkout button, and is it properly aligned?'

If an AI refactors your underlying React components but the visual output remains identical, the test passes. If a developer optimizes the CSS but accidentally pushes a critical modal behind a z-index layer, a visual test catches it instantly—while a DOM test would blindly pass because the HTML node is still technically present in the document tree.

Visual verification is the only way to test software at the speed of thought. It removes the maintenance tax, stops false positives in their tracks, and empowers continuous development instead of blocking it. We are done testing the code. We are testing the product.

Author

Tanay Agarwal

Tanay Agarwal

Software Engineer