Sha256: 856e9b3542dde028848dbf2dba6447246e942fa456e6bfd8f61caac77710aa08

Contents?: true

Size: 767 Bytes

Versions: 8

Compression:

Stored size: 767 Bytes

Contents

require File.dirname(__FILE__) + '/../../spec_helper'
require 'statemachine/generate/dot_graph/dot_graph_statemachine'

describe Statemachine::Statemachine, "(Turn Stile)" do
  include TurnstileStatemachine

  before(:each) do
    remove_test_dir("dot")
    @output = test_dir("dot")
    create_turnstile
  end

#  it "should output to console when no output dir provided" do
#    # Note - this test doesn't verify output to the console, but it does
#    # ensure that the to_dot call does not fail if not output is provided.
#    @sm.to_dot
#  end

  it "should generate a basic graph declaration" do
    @sm.to_dot(:output => @output)

    dot = load_lines(@output, "main.dot")

    dot.should_not equal(nil)
    dot[0].include?("digraph").should == true
  end
end

Version data entries

8 entries across 8 versions & 2 rubygems

Version Path
MINT-statemachine-1.5.0 spec/generate/dot_graph/dot_graph_stagemachine_spec.rb
MINT-statemachine-1.4.1 spec/generate/dot_graph/dot_graph_stagemachine_spec.rb
MINT-statemachine-1.4.0 spec/generate/dot_graph/dot_graph_stagemachine_spec.rb
MINT-statemachine-1.3.2 spec/generate/dot_graph/dot_graph_stagemachine_spec.rb
MINT-statemachine-1.2.3 spec/generate/dot_graph/dot_graph_stagemachine_spec.rb
MINT-statemachine-1.2.2 spec/generate/dot_graph/dot_graph_stagemachine_spec.rb
statemachine-1.2.0 spec/generate/dot_graph/dot_graph_stagemachine_spec.rb
statemachine-1.1.1 spec/generate/dot_graph/dot_graph_stagemachine_spec.rb