Sha256: 08bcde687cfd36e8154a1fb231fe9cfd80e8d69594dad24cf30ce2ffbab8cbc3
Contents?: true
Size: 661 Bytes
Versions: 2
Compression:
Stored size: 661 Bytes
Contents
# encoding: utf-8 require 'spec_helper' RSpec.describe FiniteMachine::EventsChain, '#insert' do let(:object) { described_class } let(:machine) { double(:machine) } subject(:chain) { object.new(machine) } it "inspects empty chain" do expect(chain.inspect).to eq("<#FiniteMachine::EventsChain @chain={}>") end it "inspect chain" do event = double(:event) chain.add(:validated, event) expect(chain.inspect).to eq("<#FiniteMachine::EventsChain @chain=#{{validated: event}}>") end it "prints chain" do event = double(:event) chain.add(:validated, event) expect(chain.to_s).to eq("#{{validated: event}}") end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
finite_machine-0.10.2 | spec/unit/events_chain/inspect_spec.rb |
finite_machine-0.10.1 | spec/unit/events_chain/inspect_spec.rb |