Error Management & Self-Healing
Overview
When a test step encounters an unexpected result in SAP — a validation error, a missing document, a blocking popup — AI@Test does not simply fail the test. Instead, it reads the situation, understands what went wrong, and tries to correct it. This capability is called self-healing.
The process works in four layers, from the simplest and fastest check to the most thorough visual analysis. Most errors are resolved at layer 1 or 2 without ever needing a screenshot.
The Four-Layer Error Detection Model
🔍 CLICK TO ENLARGE
AI@Test — Error Detection & Self-Healing
Four layers from instant text-based detection to visual fallback
1
📊Status Bar — Instant text detectionFastest · No screenshot needed
Primary · Runs after every single action
SAP always shows a message in the status bar after any operation. AI@Test reads this message as text: the type (Success / Error / Warning / Info) and the message content. Most errors — wrong value, missing field, authorisation issue — appear here immediately.
Example: "Customer 99999 does not exist" → AI corrects the customer number and retries
2
💬Popup Detection — Structured dialog readingText-based · No screenshot needed
Secondary · Triggered when a dialog appears
SAP often shows error details in a modal popup window. AI@Test reads the popup as structured text: its title, the full message content, and the list of available buttons. The agent decides how to handle it — confirm, cancel, or fill additional information before closing.
Example: "Enter a valid material group" → AI reads popup, fills the missing field, confirms
3
🔍Screen Re-observation — Full state analysisScreen-level · No screenshot needed
Tertiary · After navigation or submission
After any action that changes the screen, AI@Test reads the full new screen state: which transaction is active, what screen number it is on, which fields are present and editable. This catches silent failures — cases where SAP did not show an error but navigated to an unexpected screen.
Example: Expected to land on sales order confirmation but stayed on entry screen → AI re-evaluates and corrects
4
📸Screenshot — Visual fallback analysisVisual fallback · ~200KB context
Last resort · Used only when text data is insufficient
When the structured screen data does not explain the situation — unusual layout, custom screen, unexpected visual state — AI@Test captures a screenshot and sends it directly to the AI vision model for analysis. This is the most thorough check but also the least frequently needed.
Example: Non-standard popup with image-based error indicator → AI reads screenshot visually, identifies issue
AFTER RESOLUTION →
✅Retry succeeds
Next step proceeds
🔁Further iterations
Up to configured max retries
🐛Defect created
Cannot self-heal → logged
📄Report generated
AI explains what failed and why
What This Means in Practice
For functional testers and business analysts, AI@Test self-healing means:
- A test does not fail just because a field label changed after a transport
- A test does not fail just because a confirmation popup appeared unexpectedly
- A test does not fail just because the system added leading zeros to a number you entered
The agent handles these common SAP behaviours automatically. You see results, not noise.
For test managers, this means fewer false positives in your test results. When AI@Test does log a defect, it is because the system genuinely behaved incorrectly — not because the test script was too rigid.
For auditors and sign-off, every step — including every error encountered and every correction applied — is logged with a timestamp, the message text read from SAP, and a screenshot if captured. The audit trail is complete.
Defect Creation
When a test step cannot be resolved after all self-healing attempts, AI@Test creates a defect record automatically. The defect includes:
| Field | Content |
|---|
| Title | Test case name + step description |
| Status bar message | Exact SAP error text as read from the screen |
| Popup content | Full popup message if one was present |
| Screenshot | Visual evidence of the failing screen state |
| Test data used | The exact values entered at the point of failure |
| Recommendations | AI-generated analysis of likely cause and suggested fix |
Defects are pushed to Jira Xray or qTest via their standard APIs, or exported as a structured JSON file for integration with other tools.