Dependency Update Until Green
Automated loop to safely upgrade project dependencies while ensuring all tests pass after each update. The agent incrementally updates out-of-date packages a…
This loop is republished with attribution. Full credit and the original content belong to the source linked above.
AI Skill Market Insights
Real data. Real impact.
Emerging
Developers
Kickoff Prompt
Copy this prompt and run it with your agent to start the loop.
Start the "Dependency Update Until Green" loop.
Goal: Upgrade dependencies safely with test coverage validation
Max iterations: 10
Between iterations run: npm test
Exit when: All tests pass successfully (exit code 0)
Begin the 'Dependency Update Until Green' process. First, check which packages are outdated using 'npm outdated'. Then, update one or two packages at a time, preferring minor/patch updates over major ones. After each update, run 'npm test' to validate functionality. If tests fail, revert the changes and try updating fewer packages. Continue this cycle until all dependencies are updated and tests pass, or until 10 iterations have been completed. Ensure you back up package-lock.json before making changes and prioritize development dependencies first.
Self-pace this loop. After each iteration, run `npm test` and evaluate the output, and only continue if the exit condition is not met (All tests pass successfully (exit code 0)). Stop when the exit condition passes or 10 iterations are reached. Give a short status update each pass.