<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: exclusive gateway test case in Alfresco Archive</title>
    <link>https://connect.hyland.com/t5/alfresco-archive/exclusive-gateway-test-case/m-p/125548#M88345</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;You should use activitiRule.getRuntimeService() , like described here:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://www.activiti.org/userguide/index.html#apiUnitTesting" rel="nofollow noopener noreferrer"&gt;http://www.activiti.org/userguide/index.html#apiUnitTesting&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Best regards,&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 04 Jan 2013 10:45:48 GMT</pubDate>
    <dc:creator>trademak</dc:creator>
    <dc:date>2013-01-04T10:45:48Z</dc:date>
    <item>
      <title>exclusive gateway test case</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/exclusive-gateway-test-case/m-p/125545#M88342</link>
      <description>Hello I don't know how I should write the test for the following exclusive gateway:&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;lt;exclusiveGateway id="XORAProjectOrNot" name="" /&amp;gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;lt;sequenceFlow id="flow63" name="Project" sourceRef="XORAProjectOrNot"&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;targetRef="sendInformationsFromTheProfessors"&amp;gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;lt;condition</description>
      <pubDate>Fri, 04 Jan 2013 07:20:13 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/exclusive-gateway-test-case/m-p/125545#M88342</guid>
      <dc:creator>tomi87</dc:creator>
      <dc:date>2013-01-04T07:20:13Z</dc:date>
    </item>
    <item>
      <title>Re: exclusive gateway test case</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/exclusive-gateway-test-case/m-p/125546#M88343</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;You need to put a variable with name studentAppInfo of type StudentAppInfo in the variables map…&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Jan 2013 07:44:01 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/exclusive-gateway-test-case/m-p/125546#M88343</guid>
      <dc:creator>ronald_van_kuij</dc:creator>
      <dc:date>2013-01-04T07:44:01Z</dc:date>
    </item>
    <item>
      <title>Re: exclusive gateway test case</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/exclusive-gateway-test-case/m-p/125547#M88344</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I understand it in this way:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;CODE&gt;&lt;BR /&gt; @Rule&lt;BR /&gt; public ActivitiRule activitiRule = new ActivitiRule("activiti.cfg-mem.xml");&lt;BR /&gt;&lt;BR /&gt; @Test&lt;BR /&gt; // deploys process with form properties&lt;BR /&gt; @Deployment(resources = { "Part1Application.bpmn20.xml" })&lt;BR /&gt; public void testProjectDecision() {&lt;BR /&gt;&amp;nbsp; StudentAppInfo studentAppInfo=new StudentAppInfo(); &lt;BR /&gt;&amp;nbsp; Map&amp;lt;String, Object&amp;gt; variables = new HashMap&amp;lt;String, Object&amp;gt;();&lt;BR /&gt;&amp;nbsp; &lt;BR /&gt;&amp;nbsp; // Test with input == true&lt;BR /&gt;&amp;nbsp; studentAppInfo.setProject(true);&lt;BR /&gt;&amp;nbsp; variables.put("input", studentAppInfo.getProject());&lt;BR /&gt;&amp;nbsp; ProcessInstance pi = runtimeService.startProcessInstanceByKey("XORAProjectOrNot", variables);&lt;BR /&gt;&amp;nbsp; Task task = taskService.createTaskQuery().processInstanceId(pi.getId()).singleResult();&lt;BR /&gt;&amp;nbsp; assertEquals("send informations from the professors", task.getName());&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp; // Test with input == false&lt;BR /&gt;&amp;nbsp; studentAppInfo.setProject(false);&lt;BR /&gt;&amp;nbsp; variables.put("input", studentAppInfo.getProject());&lt;BR /&gt;&amp;nbsp; pi = runtimeService.startProcessInstanceByKey("XORAProjectOrNot", variables);&lt;BR /&gt;&amp;nbsp; task = taskService.createTaskQuery().processInstanceId(pi.getId()).singleResult();&lt;BR /&gt;&amp;nbsp; assertEquals("XOR B Project Or Not", task.getName());&lt;BR /&gt; }&lt;BR /&gt;&lt;/CODE&gt;&lt;SPAN&gt;Is this was you mean ?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;And is it useful to enter the other values for this test ?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;And the "runtimeService" and the "taskService" still doesnt work. How can I solve this ?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;ProcessInstance pi = &lt;/SPAN&gt;&lt;SPAN style="color:#BF0000;"&gt;runtimeService&lt;/SPAN&gt;&lt;SPAN&gt;.startProcessInstanceByKey("XORAProjectOrNot", variables);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Task task = &lt;/SPAN&gt;&lt;SPAN style="color:#BF0000;"&gt;taskService&lt;/SPAN&gt;&lt;SPAN&gt;.createTaskQuery().processInstanceId(pi.getId()).singleResult();&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;pi = &lt;/SPAN&gt;&lt;SPAN style="color:#BF0000;"&gt;runtimeService&lt;/SPAN&gt;&lt;SPAN&gt;.startProcessInstanceByKey("XORAProjectOrNot", variables);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;task = &lt;/SPAN&gt;&lt;SPAN style="color:#BF0000;"&gt;taskService&lt;/SPAN&gt;&lt;SPAN&gt;.createTaskQuery().processInstanceId(pi.getId()).singleResult();&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Jan 2013 09:28:37 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/exclusive-gateway-test-case/m-p/125547#M88344</guid>
      <dc:creator>tomi87</dc:creator>
      <dc:date>2013-01-04T09:28:37Z</dc:date>
    </item>
    <item>
      <title>Re: exclusive gateway test case</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/exclusive-gateway-test-case/m-p/125548#M88345</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;You should use activitiRule.getRuntimeService() , like described here:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://www.activiti.org/userguide/index.html#apiUnitTesting" rel="nofollow noopener noreferrer"&gt;http://www.activiti.org/userguide/index.html#apiUnitTesting&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Best regards,&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Jan 2013 10:45:48 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/exclusive-gateway-test-case/m-p/125548#M88345</guid>
      <dc:creator>trademak</dc:creator>
      <dc:date>2013-01-04T10:45:48Z</dc:date>
    </item>
    <item>
      <title>Re: exclusive gateway test case</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/exclusive-gateway-test-case/m-p/125549#M88346</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Is this was you mean ?&lt;/BLOCKQUOTE&gt;&lt;SPAN&gt;No&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;CODE&gt; variables.put("input", studentAppInfo.getProject());&lt;/CODE&gt;&lt;SPAN&gt;here you set a variable named input, not a variable named 'StudentAppInfo', while here&lt;/SPAN&gt;&lt;BR /&gt;&lt;CODE&gt;&amp;lt;conditionExpression xsi:type="tFormalExpression"&amp;gt;${StudentAppInfo.project == true}&amp;lt;/conditionExpression&amp;gt;&lt;/CODE&gt;&lt;SPAN&gt;and here&lt;/SPAN&gt;&lt;BR /&gt;&lt;CODE&gt;&amp;lt;conditionExpression xsi:type="tFormalExpression"&amp;gt;${StudentAppInfo.project == false}&amp;lt;/conditionExpression&amp;gt;&lt;/CODE&gt;&lt;SPAN&gt;You reference the StudentAppInfo variable or object&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Just do&lt;/SPAN&gt;&lt;BR /&gt;&lt;CODE&gt; variables.put("StudentAppInfo", studentAppInfo);&lt;/CODE&gt;&lt;BR /&gt;&lt;SPAN&gt;This 'error' you made has nothing to do with exclusive gateways or whatever, but more with a wrong use of EL and variables…&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Jan 2013 11:23:07 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/exclusive-gateway-test-case/m-p/125549#M88346</guid>
      <dc:creator>ronald_van_kuij</dc:creator>
      <dc:date>2013-01-04T11:23:07Z</dc:date>
    </item>
  </channel>
</rss>

