*/
private void runStartProcessAndDoStuffTest() {
// test start process
JaxbCommandsRequest
cmdsRequest = new JaxbCommandsRequest(DEPLOYMENT_ID, new StartProcessCommand(TEST_PROCESS_DEF_NAME));
JaxbCommandsResponse
resp = this.jmsProcessJaxbCommandsRequest(cmdsRequest);
// check response
assertNotNull( "Null response", resp);
List<JaxbCommandResponse<?>> resplist = resp.getResponses();
assertNotNull( "Null response list", resplist);
assertEquals( "Incorrect resp list size", 1, resplist.size() );
JaxbCommandResponse<?> realResp = resplist.get(0);
assertFalse( "An exception was thrown!", realResp instanceof JaxbExceptionResponse );
assertTrue( "Expected process instance response", realResp instanceof JaxbProcessInstanceResponse );
JaxbProcessInstanceResponse procInstResp = (JaxbProcessInstanceResponse) realResp;
assertNotNull( "Null process instance", procInstResp);
assertEquals( "Invalid process instance id", TEST_PROCESS_INST_ID, procInstResp.getId() );
// Do rest call with process instance id this time. This will fail if:
// - the ProcessInstanceIdContext is not used (and an EmptyContext is used instead)
// - The ProcessInstanceIdContext constructor gets a null value for the process instance id
cmdsRequest = new JaxbCommandsRequest(DEPLOYMENT_ID, new SignalEventCommand(TEST_PROCESS_INST_ID, "test", null));
cmdsRequest.setVersion(ServicesVersion.VERSION);
cmdsRequest.setProcessInstanceId(TEST_PROCESS_INST_ID);
resp = this.jmsProcessJaxbCommandsRequest(cmdsRequest);
// check response
assertNotNull( "Null response", resp);
resplist = resp.getResponses();
assertNotNull( "Null response list", resplist);
assertEquals( "Incorrect resp list size", 1, resplist.size() );
realResp = resplist.get(0);
assertFalse( "An exception was thrown!", realResp instanceof JaxbExceptionResponse );