Hi, this is my first post here, so please forgive me if this is a faq. As the subject says, I'd like to test a participant (and, more generally, a process involving several participants). The only example I have found in the documentation (at http://ruote.rubyforge.org/testing_processes.html) involves undefined participants (intercepted with catchall). As soon as I modify the example to deal with a “real” participant, I get an error, as the following minimal example shows:
ENGINE = Ruote::Engine.new(Ruote::Worker.new(Ruote::HashStorage.new())) ENGINE.register_participant :dummy do |workitem| workitem.result = 10 end pdef = Ruote.process_definition do dummy end wfid = ENGINE.launch(pdef) ENGINE.wait_for(:dummy) workitem = ENGINE.storage_participant.first puts workitem.result # should be 10 ENGINE.storage_participant.reply(workitem) ENGINE.wait_for(wfid) but it fails because the retrieved workitem is nil. Apparently, but not obviously (at least for me), I am doing something wrong. I am using Ruote 2.2.0 and Ruby 1.9.2. How can the above be fixed? Nicola -- you received this message because you are subscribed to the "ruote users" group. to post : send email to [email protected] to unsubscribe : send email to [email protected] more options : http://groups.google.com/group/openwferu-users?hl=en
