Thursday, January 3, 2013

A few tricks for better build pipelines

  1. Monitor fails - each failed build needs to be logged and have a quick post mortem. Identify which test failed and why. If not why, track the test over time and look for patterns. Lots of teams just say, "the test is flaky" and move on. 
  2. Run failed tests first. When there is a fail (and assuming it was logged in step 1), the pipleline can be set to pick up that test first. If it fails, then the regression is still present and the pipeline should run red again.
  3. Prioritize test order - have the business critical tests run in an earlier stage than others so devs get faster feedback when they've screwed something. 
  4. Short feedback cycles. Rule of thumb I use is to try and keep it under 10 mins. When you breach this, it's time to talk about parallelization / performance testing / magic wanding.