8 August 2010

Faster cucumber features.

“My tests are running” is the new “My code is compiling”.

Features that take forever to run either make me lose focus or makes it an unpleasant experience dealing with tests.

Recently I was introduced to parallel_tests, a gem that makes use of all the CPU’s on your development machine to run tests in parallel.

Parallel Tests uses the size of feature files as an indication of how long it takes to run, then creates n groups of feature files, where n is the number of processors on your dev machine. Each group is then processed by a CPU.

I managed to reduce the runtime of my features by ~30% using the parallel_tests gem. Your mileage, as always, may vary.

ARTICLE BY
Ivor Paul

We'd love to hear from you: