testRoundTrip(resp);
}
@Test
public void historyLogListTest() throws Exception {
JaxbHistoryLogList resp = new JaxbHistoryLogList();
testRoundTrip(resp);
// vLog
org.jbpm.process.audit.VariableInstanceLog vLog = new org.jbpm.process.audit.VariableInstanceLog(23, "process", "varInst", "var", "two", "one");
vLog.setExternalId("domain");
Field dateField = org.jbpm.process.audit.VariableInstanceLog.class.getDeclaredField("date");
dateField.setAccessible(true);
dateField.set(vLog, new Date());
Field idField = org.jbpm.process.audit.VariableInstanceLog.class.getDeclaredField("id");
idField.setAccessible(true);
idField.set(vLog, 32l);
resp.getHistoryLogList().add(new JaxbVariableInstanceLog(vLog));
// pLog
org.jbpm.process.audit.ProcessInstanceLog pLog = new org.jbpm.process.audit.ProcessInstanceLog(23, "process");
pLog.setDuration(2000l);
pLog.setEnd(new Date());
pLog.setExternalId("domain");
pLog.setIdentity("id");
pLog.setOutcome("error");
pLog.setParentProcessInstanceId(42);
pLog.setProcessName("name");
pLog.setProcessVersion("1-SNAP");
pLog.setStatus(2);
idField = org.jbpm.process.audit.ProcessInstanceLog.class.getDeclaredField("id");
idField.setAccessible(true);
idField.set(pLog, 32l);
resp.getHistoryLogList().add(new JaxbProcessInstanceLog(pLog));
// nLog
org.jbpm.process.audit.NodeInstanceLog nLog = new org.jbpm.process.audit.NodeInstanceLog(0, 23, "process", "nodeInst", "node", "wally");
idField = org.jbpm.process.audit.NodeInstanceLog.class.getDeclaredField("id");
idField.setAccessible(true);
idField.set(nLog, 32l);
dateField = org.jbpm.process.audit.NodeInstanceLog.class.getDeclaredField("date");
dateField.setAccessible(true);
dateField.set(nLog, new Date());
nLog.setNodeType("type");
nLog.setWorkItemId(88l);
nLog.setConnection("connex");
nLog.setExternalId("domain");
resp.getHistoryLogList().add(new JaxbNodeInstanceLog(nLog));
testRoundTrip(resp);
}