class StateDrawingNonFinalTest

Public Instance Methods

setup() click to toggle source
# File test/unit/state_test.rb, line 910
def setup
  @machine = StateMachine::Machine.new(Class.new)
  @machine.states << @state = StateMachine::State.new(@machine, :parked)
  @machine.event :ignite do
    transition :parked => :idling
  end
  
  graph = GraphViz.new('G')
  @node = @state.draw(graph)
end
test_should_use_ellipse_as_shape() click to toggle source
# File test/unit/state_test.rb, line 921
def test_should_use_ellipse_as_shape
  assert_equal 'ellipse', @node['shape'].to_s.gsub('"', '')
end