Registry / testing / spy
library1.0.5rbrubygemsunverified

A modern mocking library that raises errors on stubbing nonexistent methods or wrong arity.

gem install spy
INSTALL
IMPORT
SIG · SPY
S
spy
testingrubyv1.0.5
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

Spy
require 'spy'

Create a spy and stub a method

require 'spy' obj = spy('obj') allow(obj).to receive(:foo).and_return(42) puts obj.foo
Debug
Known issues
breakingRequires Ruby 2.1.0 or higher
fix
Upgrade Ruby to version 2.1.0 or later
affects: < 1.0.0
Upgrade
Version history
1.0.5latest on RubyGems
Audit
Dependencies

No dependency data recorded yet.

Agent activity
6 hits · last 30 days
node
6
Resources
spy — gem install spy · libregistry