upgrade rspec
remove warnings about un-initialised variables
switch from == to eq to remove warnings
remove warnings about variable shadowing
remove warning about ambiguous arguments
using stub to create test doubles is deprecated, use double directly
specifying an error not to raise is deprecated
stub! is deprecated and will be removed, use stub
fix spec that was wrongly passing before