Class: RSpec::Mocks::ArgumentMatchers::InstanceOf Private
| Relationships & Source Files | |
| Inherits: | Object |
| Defined in: | rspec-mocks/lib/rspec/mocks/argument_matchers.rb |
Class Method Summary
- .new(klass) ⇒ InstanceOf constructor Internal use only
Instance Method Summary
- #===(actual) Internal use only
- #description Internal use only
Constructor Details
.new(klass) ⇒ InstanceOf
# File 'rspec-mocks/lib/rspec/mocks/argument_matchers.rb', line 322
def initialize(klass) @klass = klass end
Instance Method Details
#===(actual)
[ GitHub ]# File 'rspec-mocks/lib/rspec/mocks/argument_matchers.rb', line 326
def ===(actual) actual.instance_of?(@klass) end
#description
[ GitHub ]# File 'rspec-mocks/lib/rspec/mocks/argument_matchers.rb', line 330
def description "an_instance_of(#{@klass.name})" end