123456789_123456789_123456789_123456789_123456789_

Class: RSpec::Mocks::ArgumentMatchers::DuckTypeMatcher Private

Do not use. This class is for internal use only.
Relationships & Source Files
Inherits: Object
Defined in: rspec-mocks/lib/rspec/mocks/argument_matchers.rb

Class Method Summary

Instance Method Summary

Instance Method Details

#===(value)

[ GitHub ]

  
# File 'rspec-mocks/lib/rspec/mocks/argument_matchers.rb', line 311

def ===(value)
  @methods_to_respond_to.all? { |message| value.respond_to?(message) }
end

#description

[ GitHub ]

  
# File 'rspec-mocks/lib/rspec/mocks/argument_matchers.rb', line 315

def description
  "duck_type(#{@methods_to_respond_to.map(&:inspect).join(', ')})"
end