[rspec-users] Mocks: expectations vs spying
Ashley Moran
ashley.moran at patchspace.co.uk
Thu Oct 16 16:47:10 EDT 2008
Hi again
Ok, so I'm having a little research fling with JavaScript, and I've
uncovered something I hadn't seen before: "spying". Basically,
inspecting mocks after-the-fact, rather than setting expectations
upfront.
Here are the articles I found:
http://ajaxian.com/archives/mockme-a-new-javascript-mocking-framework
http://blog.johanneslink.net/2008/08/08/ajax-travelogue-part-6-mocking-in-javascript/
http://blog.johanneslink.net/2008/08/09/ajax-travelogue-part-7-mockme/
Does anyone know more about this technique, and its pros and cons vs
expectation-based mocking as used in RSpec mocks?
Thanks for any info
Ashley
--
http://www.patchspace.co.uk/
http://aviewfromafar.net/
More information about the rspec-users
mailing list