Make it impossible to deploy if tests fail

This is part of the Semicolon&Sons Code Diary - consisting of lessons learned on the job. You're in the testing category.

Last Updated: 2024-03-28

For the umpteenth time in my programming career, I've seen people pushing code into production without waiting for the green results of continuous integration tests first.

We paid a big price for it lately, in that someone pushed a bug that made a major customer acquisition channel silently break (due to validation errors).

This persisted for 10 days until I became aware of it.

I addressed this issue by updating my deploy script to read the latest result from CircleCI and refusing to push if master fails. The slow-down in deploying is justified by the avoidance of screw-ups.