# Self-healing: how AI repairs a broken test

> Self-healing repairs a test when the site changes. Three approaches with AI, from the most guided to the most autonomous, and their limits (ParisTestConf 2026).

Source: https://qanary.dev/en/blog/self-healing-tests-with-ai  
Product: Qanary, no-code automated testing for e-commerce  
Site index for AI assistants: https://qanary.dev/en/llms.txt

[Blog](https://qanary.dev/en/blog) · Talk

Self-healing repairs a test when the site changes. Three approaches with AI, from the most guided to the most autonomous, and their limits (ParisTestConf 2026).

[Antoine Bouchet](https://qanary.dev/en/about#antoine), CEO of Qanary, March 30, 2026 · 4 min read

The demos from this talk are on GitHub: [ParisTestConf 2026](https://github.com/qanary-labs/ParisTestConf2026) and [UCAAT 2026](https://github.com/qanary-labs/UCAAT2026).

## Self-healing tests: what we shared at ParisTestConf

The paradox nobody dares to admit.

We asked the room: “Raise your hand if you automate tests.”

Lots of hands.

“Keep your hand up if test automation frustrates you.”

The hands stayed up.

That’s the **paradox** of automation. You automate to save time. But the bigger the test suite gets, the more maintenance explodes. A DOM that changes, flaky async timing, a simple code refactor… and the dashboard turns red.

The worst part? Often it isn’t your application that’s buggy. It’s your tests. The thing that’s supposed to catch bugs is buggy itself.

That’s the problem Steven and I set out to tackle with this talk at ParisTestConf, and it’s at the heart of what we’re building at Qanary.

## What is self-healing, in practice?

**Self-healing** is the ability of a test system to repair itself automatically when something breaks.

The principle, in three steps:

1. The algorithm detects that an element can no longer be found.
2. It works out how to adapt the test: change the selector, adjust the structure.
3. It stabilizes the test suite with no human intervention.

The benefits are direct: less time spent on maintenance, a more stable test suite, coverage that can scale, and faster release cycles.

It isn’t new. Algorithmic and machine learning approaches already existed. But in the last few months, generative AI (LLMs) has opened up new possibilities. And that’s what we came to show.

## Three approaches, from the most guided to the most autonomous

We built the talk around three increasing levels of autonomy. Every demo was real, on Playwright, and you can reproduce it at home.

### 1. Playwright agents (low autonomy)

Released in October 2025, Playwright agents come with three components:

1. A planner, which explores the site and identifies journeys to cover.
2. A generator, which generates the test cases.
3. A healer, which observes the page and repairs the test when a selector breaks.

It’s good. It’s built in. But it’s very consultative: the tool regularly asks you what to do. You stay very much in the loop.

[See the demo on GitHub](https://github.com/qanary-labs/ParisTestConf2026)

### 2. Claude Code on the command line (medium autonomy)

The idea here: what if you could work without opening the IDE? From a simple terminal, or even by voice?

You hand Claude Code the job of detecting the problem, finding a solution, and updating the code directly. You approve; you don’t script.

The real power? This kind of approach can be triggered from an automation tool, from Slack, or from a Jenkins or GitLab CI pipeline. A first step toward self-healing that runs without you.

[See the demo on GitHub](https://github.com/qanary-labs/ParisTestConf2026)

### 3. Multi-agent (maximum autonomy)

Here, we go straight into CI with Claude Code. You find a classic team structure: a PO, a QA engineer, a developer. Except they’re sub-agents.

You give one instruction. Depending on the context, it’s distributed to the agents, who work together, step by step, to repair the tests, without you having to step in.

It’s the highest level of autonomy. And we deliberately pushed it a little beyond pure self-healing, to show what’s already possible.

[See the demo on GitHub](https://github.com/qanary-labs/ParisTestConf2026)

## What not to do

We insisted on the limits, because an honest talk also covers what doesn’t work.

**The danger of the false negative.** If a button disappears because a product is out of stock, the AI must not invent a click on another element. The goal isn’t for everything to be green. It’s to know the truth about the state of your application.

**The cost of LLMs.** These models use tokens. Multi-agent setups in particular. In the vast majority of cases, the ROI stays positive. But you need to plan for it.

**AI is not an intern you can hand everything off to.** Bringing in these tools is a project in its own right. You have to test, check, and validate what they produce. You remain responsible for quality, whatever happens.

## What it really changes

Self-healing doesn’t eliminate the tester’s role. It shifts it.

You’re no longer the mechanic fixing broken selectors one by one. You become the architect who decides what to cover, why, and in what order.

Your value isn’t scripting. It’s understanding the product, understanding the business, knowing what really matters to test. AI answers “how to repair.” You answer “what to automate.”

That’s the conviction behind Qanary: making QA more accessible, more autonomous, and above all more honest about what it really costs in time.

If you were at the conference and want to dig deeper, or if you’d like to try Qanary on your project, we’re here.

Want to see Qanary test your site? Book your free 30-minute test run with Julia or Antoine.

**Antoine Bouchet** Ten years in product management, on high-impact sites. He wants to raise the quality of online stores, with a product that does exactly what its users need. [More about Antoine](https://qanary.dev/en/about#antoine)

## Read next

- Guide
  ### [Build a testing agent with Claude Code and Playwright](https://qanary.dev/en/blog/testing-agent-claude-code-playwright)
  One folder, one command: Claude explores a site, plans its tests, runs them with Playwright, and delivers a report backed by proof. 15 minutes to set up.
  **Antoine Bouchet**, June 2, 2026 · 7 min read
- Talk
  ### [The quality mindset: how to ship flawless WordPress sites](https://qanary.dev/en/blog/quality-mindset-wordpress-sites)
  Define your critical journeys, document them in a spreadsheet, and move from reactive quality to quality you control: our talk at WordCamp Nice 2026.
  **Antoine Bouchet**, February 13, 2026 · 2 min read
- Guide
  ### [How to create an automated test with AI, step by step](https://qanary.dev/en/blog/create-an-automated-test-with-ai)
  AI writes the skeleton, the Playwright recorder supplies the real selectors, and you keep the judgment: a checkout test in about twenty minutes.
  **Antoine Bouchet**, January 26, 2026 · 5 min read

[All articles](https://qanary.dev/en/blog)
