class BranchDrawingWithoutToRequirementTest

Public Instance Methods

setup() click to toggle source
# File test/unit/branch_test.rb, line 854
def setup
  @machine = StateMachine::Machine.new(Class.new)
  
  graph = GraphViz.new('G')
  graph.add_node('parked')
  
  @branch = StateMachine::Branch.new(:from => :parked)
  @edges = @branch.draw(graph, :park, [:parked])
end
test_should_create_loopback_edge() click to toggle source
# File test/unit/branch_test.rb, line 864
def test_should_create_loopback_edge
  assert_equal 'parked', @edges.first.instance_variable_get('@xNodeOne')
  assert_equal 'parked', @edges.first.instance_variable_get('@xNodeTwo')
end