method
duck_type
1.3.0 -
Show latest stable
- Class:
Spec::Mocks::ArgumentMatchers
duck_type(*args)public
Passes if the argument responds to the specified messages.
Examples
array = [] display = mock('display') display.should_receive(:present_names).with(duck_type(:length, :each)) => passes