Sha256: 6eb7c140cf7b47843dd5c2c6f06a0801b62c86b10ccdc6caccd8c2d1c4e3c731
Contents?: true
Size: 1.29 KB
Versions: 3
Compression:
Stored size: 1.29 KB
Contents
# # Testing Ruote (OpenWFEru) # # Sat Jan 24 22:40:35 JST 2009 # require File.join(File.dirname(__FILE__), 'base') require 'ruote/part/hash_participant' class EftProcessDefinitionTest < Test::Unit::TestCase include FunctionalBase def test_empty_procdef assert_trace( Ruote.define(:name => 'test_1') { }, '') end def test_sub_definition pdef = Ruote.process_definition :name => 'main' do define :name => 'sub0' do end participant :ref => :alpha end alpha = @engine.register_participant :alpha, Ruote::HashParticipant #noisy wfid = @engine.launch(pdef) wait_for(:alpha) ps = @engine.process(wfid) assert_equal( {"sub0"=> ["0_0", ["define", {"name"=>"sub0"}, []]], "main"=> ["0", ["define", {"name"=>"main"}, [["define", {"name"=>"sub0"}, []], ["participant", {"ref"=>"alpha"}, []]]]]}, ps.variables) end #def test_define_implicit_name # pdef = Ruote.define 'accounting_process' do # end # assert_equal 'accounting_process', pdef[1]['name'] #end def test_sub_define_implicit_name pdef = Ruote.define 'accounting_process' do define 'sub0' do end end assert_equal( ["define", {"accounting_process"=>nil}, [["define", {"sub0"=>nil}, []]]], pdef) end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
ruote-2.1.3 | test/functional/eft_0_process_definition.rb |
ruote-2.1.2 | test/functional/eft_0_process_definition.rb |
ruote-2.1.1 | test/functional/eft_0_process_definition.rb |