106 / 168 · 01 Agent Skills for Browser Automation · Self-Healing Strategies for Agent-Driven Tests← prev⊞ allnext →☰ Read as one page
14.6Tracking Self-Healing Events
Log every healing event for analysis:
{
"timestamp": "2026-07-09T14:23:05Z",
"test": "login_valid",
"step": 4,
"expected_element": "button \"Sign in\"",
"stale_ref": "e5",
"healed_ref": "e8",
"healing_level": 1,
"reason": "Button renamed from 'Submit' to 'Sign in' in UI refresh"
}
Review healing logs weekly:
- High healing rate on one test → Regenerate or hand-fix that test
- High healing rate across tests → Major UI refactor happened; rerun the planner/generator over the affected area instead of healing test-by-test
- Healing always escalating to Level 3 → Your test flows are too coupled to page structure; push for accessible names and test IDs