Class: NeuronCheckSystem::SelfMatcher
- Inherits:
-
MatcherBase
- Object
- MatcherBase
- NeuronCheckSystem::SelfMatcher
- Defined in:
- lib/neuroncheck/matcher.rb
Overview
selfであるかどうかを判定 (通常はreturns用)
Instance Attribute Summary
Attributes inherited from MatcherBase
Instance Method Summary collapse
- #expected_caption ⇒ Object
- #expected_short_caption ⇒ Object
-
#initialize(declared_caller_locations) ⇒ SelfMatcher
constructor
A new instance of SelfMatcher.
- #match?(value, self_object) ⇒ Boolean
Methods inherited from MatcherBase
#get_error_message, #meta_info_as_json
Constructor Details
#initialize(declared_caller_locations) ⇒ SelfMatcher
Returns a new instance of SelfMatcher.
198 199 200 |
# File 'lib/neuroncheck/matcher.rb', line 198 def initialize(declared_caller_locations) @declared_caller_locations = declared_caller_locations end |
Instance Method Details
#expected_caption ⇒ Object
206 207 208 |
# File 'lib/neuroncheck/matcher.rb', line 206 def expected_caption "self" end |
#expected_short_caption ⇒ Object
209 210 211 |
# File 'lib/neuroncheck/matcher.rb', line 209 def expected_short_caption "self" end |
#match?(value, self_object) ⇒ Boolean
202 203 204 |
# File 'lib/neuroncheck/matcher.rb', line 202 def match?(value, self_object) self_object.equal?(value) end |