assert_chaos_handled
Injects a chaos HTTP status into matching requests and asserts whether the app shows fallback UI and survives without unhandled exceptions.
Instructions
Opens the browser, navigates to the application, and injects a chaos HTTP status into all matching requests. Checks: did the app show fallback UI, were there unhandled exceptions, and did it survive? Use to answer: is the app chaos-resilient — does it show a recovery UI without throwing exceptions?
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"url": "<url>",
"intercept_pattern": "<intercept_pattern>"
},
"name": "assert_chaos_handled"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | URL of the page to test | |
| wait_ms | No | Milliseconds to wait after navigation before evaluating verdict (default: 2000) | |
| headless | No | Whether to run in headless mode (default: false, launches real browser so user sees application) | |
| viewport | No | Viewport size (default: 1280×720) | |
| http_status | No | HTTP error status to return for all matching requests (default: 500) | |
| preview_delay_ms | No | Milliseconds to pause after simulation before closing browser, allowing visual inspection (default: 2000) | |
| intercept_pattern | Yes | Glob pattern for requests to fail (e.g., '**/api/**') | |
| keep_browser_open | No | Keep browser window open after test completes so user can interactively inspect the app (default: false) | |
| api_health_check_url | No | Optional backend or hosted API health check URL to verify before running chaos test. Aborts if backend is down or errors. | |
| expected_fallback_selector | No | CSS selector for the fallback/error UI expected to appear (e.g., '.error-boundary'). chaos_survived is true only when this is found AND there are no unhandled exceptions. |