Author: jim.ma
Date: 2009-07-21 01:55:48 -0400 (Tue, 21 Jul 2009)
New Revision: 5328
Modified:
jbpm4/trunk/modules/migration/src/main/java/org/jbpm/jpdl/internal/convert/Jpdl3Converter.java
jbpm4/trunk/modules/migration/src/test/java/org/jbpm/jpdl/internal/convert/Jpdl3ConverterReaderTest.java
jbpm4/trunk/modules/migration/src/test/resources/script.xml
Log:
JBPM-2388:Fixed continue attribute
Modified:
jbpm4/trunk/modules/migration/src/main/java/org/jbpm/jpdl/internal/convert/Jpdl3Converter.java
===================================================================
---
jbpm4/trunk/modules/migration/src/main/java/org/jbpm/jpdl/internal/convert/Jpdl3Converter.java 2009-07-21
05:08:11 UTC (rev 5327)
+++
jbpm4/trunk/modules/migration/src/main/java/org/jbpm/jpdl/internal/convert/Jpdl3Converter.java 2009-07-21
05:55:48 UTC (rev 5328)
@@ -569,11 +569,11 @@
String asyncText = jpdl3Element.attributeValue("async");
if ("true".equalsIgnoreCase(asyncText)) {
- jpdl4Element.addAttribute("asyn", "true");
+ jpdl4Element.addAttribute("continue", "async");
}
else if ("exclusive".equalsIgnoreCase(asyncText)) {
- jpdl4Element.addAttribute("asyn", "exclusive");
- }
+ jpdl4Element.addAttribute("continue", "exclusive");
+ }//else if -> uses the default continue="sync"
// parse common subelements
Modified:
jbpm4/trunk/modules/migration/src/test/java/org/jbpm/jpdl/internal/convert/Jpdl3ConverterReaderTest.java
===================================================================
---
jbpm4/trunk/modules/migration/src/test/java/org/jbpm/jpdl/internal/convert/Jpdl3ConverterReaderTest.java 2009-07-21
05:08:11 UTC (rev 5327)
+++
jbpm4/trunk/modules/migration/src/test/java/org/jbpm/jpdl/internal/convert/Jpdl3ConverterReaderTest.java 2009-07-21
05:55:48 UTC (rev 5328)
@@ -79,7 +79,10 @@
@Test
public void testScript() throws Exception {
setUpEnviroment();
- testConvert("script.xml");
+ Document doc = convert("script.xml");
+ Element stateEle = doc.getRootElement().element("state");
+ Assert.assertEquals("async", stateEle.attributeValue("continue"));
+ validate(doc);
}
@Test
Modified: jbpm4/trunk/modules/migration/src/test/resources/script.xml
===================================================================
--- jbpm4/trunk/modules/migration/src/test/resources/script.xml 2009-07-21 05:08:11 UTC
(rev 5327)
+++ jbpm4/trunk/modules/migration/src/test/resources/script.xml 2009-07-21 05:55:48 UTC
(rev 5328)
@@ -22,7 +22,7 @@
</action>
</transition>
</start-state>
- <state name="first">
+ <state name="first" async="true">
<event type="node-enter">
<action class="com.test.NodeEnterAction"/>
</event>
Show replies by date