Mocha Shot

Mocha-Shot is a terser Mocha mock framework. It features syntax like:

require ‘rubygems’ require ‘mocha/shot’

the_mock.expects.foo(1,2) {|a, b| :bar} # equivalent to the_mock.expects(:foo).with(1,2) {|a, b| :bar}

the_mock.expects.foo(1,2).returns(:bar) # equivalent to the_mock.expects.(:foo).with(1,2).returns(:bar)