Keep and run regression scenarios
three_scenarioSave, list, and run regression scenarios built from three_play runs; replay them in CI and report each failing claim with its value and frame.
Instructions
Regression tests made from three_play runs, kept in the project as .threesmith/scenarios/.json (commit them; threesmith ci runs them and writes JUnit). op save runs the play once more with the same arguments and keeps it only when it passes (undoable with three_undo); op list shows the kept ones; op run runs one (name) or all, with every failing claim, its value and frame.
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": {
"op": "<op>"
},
"name": "three_scenario"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| op | Yes | ||
| name | No | scenario name (letters, digits, - and _); for run: exact or part of the name | |
| path | No | Project folder, or a file or folder in it (relative to the server's folder; default: the project). | |
| root | No | ||
| wait | No | ||
| entry | No | ||
| steps | No | Steps in order: {"type":"click","selector":"#start"} or {x,y}, {"type":"press","key":"Space"}, {"type":"hold","key":"ArrowRight","ms":300}, {"type":"drag","from":[x,y],"to":[x,y]}, {"type":"wheel","deltaY":200}, {"type":"wait","ms":500}, {"type":"wait-for","selector":"canvas"}, {"type":"frames","n":10}, {"type":"eval","js":"app.start()"}, {"type":"until","js":"$('ball').position.y < 0","timeout":5000}. | |
| watch | No | ||
| width | No | ||
| expect | No | Claims about the scene: "$('player').position.y > 1 @ end", "any: $('door').rotation.y > 1", "always: info.render.calls < 200", "x @ step 2", or {js, at}. | |
| height | No | ||
| target | No | Folder with the page (index.html), or the http(s) URL of a running dev server. | |
| overwrite | No |