Permalink
Browse files

Fixing RSpec deprecation warning 'mock is deprecated. Use double inst…

…ead.'
  • Loading branch information...
1 parent 5225fa9 commit 6da72a954f5f9723173788b18fb0f2af3a8d1b26 James White committed with ggilder Feb 8, 2014
Showing with 3 additions and 3 deletions.
  1. +3 −3 spec/command_spec.rb
@@ -50,21 +50,21 @@
end
it "calling the #call method by default when an object is called" do
- object = mock 'Object'
+ object = double 'Object'
object.should_receive(:call).once
@command.when_called object
@command.run 'foo'
end
it "should allow #action as an alias to #when_called" do
- object = mock 'Object'
+ object = double 'Object'
object.should_receive(:call).once
@command.action object
@command.run 'foo'
end
it "calling an arbitrary method when an object is called" do
- object = mock 'Object'
+ object = double 'Object'
object.should_receive(:foo).once
@command.when_called object, :foo
@command.run 'foo'

0 comments on commit 6da72a9

Please sign in to comment.