Failing test fix
When another program asks, the build is run, and an agent fixes it until it passes.
In words
The wishThe build is green again
Step 1 · build
What to doBuild and test the project.
Who does itAn algorithm runs
make checkWhat proves it
- Another agent must find this true: “The fix changes the code that was wrong, and does not skip, remove or weaken a test.”
The file
json
{
"$schema": "vpf/1",
"wish": "The build is green again",
"start": {
"on": "request"
},
"limits": {
"repeats": 5,
"minutes": 45
},
"steps": [
{
"id": "build",
"do": "Build and test the project.",
"by": "algorithm",
"run": "make check",
"on_fail": "agent",
"proof": {
"by": "agent",
"check": "The fix changes the code that was wrong, and does not skip, remove or weaken a test."
}
}
]
}Why it is written this way
One step does it all: the command fails, an agent fixes the code, and the command runs again as the proof, followed by an agent that makes sure no test was skipped.