Sam Phippen - Anatomy of a mocked call
Channel: Lyon.rb
Date: 02/02/2015

Recorded at RuLu 2014. http://rulu.eu/

RSpec is often accused of being "full of magic". For the most part: I disagree. However: mocking a method on an object, calling it, recording that call and then working out if expectations have been violated after the fact is a complex set of operations.

This talk will give a guided tour, with code, through RSpec's mocks. We'll look at one of the most simple cases possible. We'll also look at the most complicated case I can conceive of. Hopefully everyone will learn a little something about testing whilst watching this talk.