We’re getting to a point where our test suites are so large, it’s slowing us down.
Our main unit test run, with close to 2000 tests, takes 16 minutes on a top-specced macbook, which we’ve split in 3 smaller suites on CircleCI to speed things up (this was a game-changer for us btw, and also allowed us to park flakey tests in their own “flakey” test run).
There are various things we could do to shave off percentage points off of this, and probably up to 30% faster. But if we wanted to make it 5x faster, I don’t think we’d make it.
Our main issue is that most of our tests need the DB, and we wipe it between every unit test. We’ve used
hwillson:stub-collections in the past, but it made our tests much less trust-worthy, as all sorts of other packages would not work, and therefore you’re not really testing your application properly.
I’m left wondering if there are some different ways to dramatically speed up tests, either through parallelization, better mocking, or something else entirely?