1. 9
  1.  

  2. 4

    I feel this so strongly! When I started doing test driven development, I discovered that I can wait two seconds without changing focus. I’ve kept my personal project test suites smaller than two seconds so I can test without losing focus on what I’m building.

    One of the test suites in a work codebase takes just under ten minutes!

    How many times do you run the test suite in a day? Multiply that times the length of your test suite, see how much time productive time was removed from your day.

    Or, pick a codebase you work with often, find a way to speed up the tests, and see if that increases your productivity?

    1. 1

      One of the test suites in a work codebase takes just under ten minutes!

      How many times do you run the test suite in a day? Multiply that times the length of your test suite, see how much time productive time was removed from your day.

      I’ve tried to combat this with a model of progressive testing. We might disable the long-running tests on our local machine to pound out a couple of test cases, but every commit will queue up a real-deal full run of tests on our build server automagically.

      Maybe I do a bunch of commits in a quick series and I’ll get a nice backlog of tests churning away, but I don’t have to get distracted by them until I’m ready. Then I can look at the blob of tests that ran while I was coding and see what else I need to fix.