Sha256: d91c0f8c8ccea491a4f6c266e3fa3e0e2068bcb924cf2823cee9354a71b66426

Contents?: true

Size: 331 Bytes

Versions: 2

Compression:

Stored size: 331 Bytes

Contents

# frozen_string_literal: true

RSpec.describe FiniteMachine::EventsMap, '#clear' do
  it "clears map events" do
    event = double(:event)
    events_map = described_class.new
    events_map.add(:validated, event)
    expect(events_map.empty?).to be(false)

    events_map.clear
    expect(events_map.empty?).to be(true)
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
finite_machine-0.12.1 spec/unit/events_map/clear_spec.rb
finite_machine-0.12.0 spec/unit/events_map/clear_spec.rb