Test Doubles: in theory, in Minitest and in RSpec

Those of us that do Test Driven Development have heard about doubles, mocks, stubs, fakes and spies multiple times. Unfortunately there is a ton of confusion about all these words and their meaning. Let’s see what each an every one of these really mean, where we should use them and how the popular testing frameworks for Ruby implement these. Test Doubles So, first things first. One of the biggest misconceptions is that doubles are types of objects that are used in testing....

August 5, 2015 · 12 min · Ilija

Migrating a test suite from RSpec to Minitest

I have always wanted to have some fun with Minitest but until this weekend I never got the chance to do it. For those of you that don’t know, Minitest is a suite of testing facilities, that support TDD, BDD, mocking and benchmarking. Having wanted to play with Minitest, this weekend I decided that I will migrate the test suite of a gem of mine, from RSpec to Minitest. Read on to see how it all went....

July 14, 2015 · 7 min · Ilija