Class: ActLike::Matcher
- Inherits:
-
Object
- Object
- ActLike::Matcher
- Defined in:
- lib/act_like/matcher.rb
Instance Attribute Summary collapse
-
#offenses ⇒ Object
readonly
Returns the value of attribute offenses.
Instance Method Summary collapse
- #check ⇒ Object
-
#initialize(actual, expected) ⇒ Matcher
constructor
A new instance of Matcher.
Constructor Details
#initialize(actual, expected) ⇒ Matcher
Returns a new instance of Matcher.
5 6 7 8 9 |
# File 'lib/act_like/matcher.rb', line 5 def initialize(actual, expected) @actual = actual @expected = expected @offenses = Hash.new { |offenses, offense| offenses[offense] = Array.new } end |
Instance Attribute Details
#offenses ⇒ Object (readonly)
Returns the value of attribute offenses.
3 4 5 |
# File 'lib/act_like/matcher.rb', line 3 def offenses @offenses end |
Instance Method Details
#check ⇒ Object
11 12 13 14 |
# File 'lib/act_like/matcher.rb', line 11 def check check_class_methods check_instance_methods end |