OK...memo to myself: first test then write...

This unit test shows the use of initial. It also shows, that my first attempt 
was right.

                        ProcessDefinition processDefinition = 
ProcessDefinition.parseXmlString(
  |                                     "<process-definition" +
  |                                     " xmlns=''  name='test' 
initial='task1'>" +
  |                                     "  <task-node name='task1'>" +
  |                                     "     <task name='task1'>" +
  |                                     "     </task>" +
  |                                     "     <transition name='' 
to='end1'></transition>" +
  |                                     "  </task-node>" +
  |                                     "  <end-state name='end1'></end-state>" 
+
  |                                     "</process-definition>"
  |                       );
  |                       
  |                       ProcessInstance processInstance = new 
ProcessInstance(processDefinition);
  |                       
  |                       Token token = processInstance.getRootToken();
  |                       
  |                       assertSame(processDefinition.getNode("task1"), 
token.getNode());

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4074386#4074386

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4074386
_______________________________________________
jboss-user mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/jboss-user

Reply via email to