Class: Counter::RSpecMatchers::Base

Inherits:
RSpec::Matchers::BuiltIn::Change
  • Object
show all
Defined in:
lib/counter/rspec/matchers.rb

Direct Known Subclasses

DecrementCounterFor, IncrementCounterFor

Instance Method Summary collapse

Constructor Details

#initialize(counter_class, parent) ⇒ Base

Returns a new instance of Base.



12
13
14
# File 'lib/counter/rspec/matchers.rb', line 12

def initialize(counter_class, parent)
  super { parent.counters.find_or_create_counter!(counter_class).value }
end