692693694695696697698699700701702
.manualStart(); // then HistoricTaskInstanceQuery query = historyService.createHistoricTaskInstanceQuery(); query.caseInstanceId(caseInstanceId); assertEquals(1, query.count()); assertEquals(1, query.list().size()); assertNotNull(query.singleResult());
734735736737738739740741742743744
.manualStart(); // then HistoricTaskInstanceQuery query = historyService.createHistoricTaskInstanceQuery(); query.caseInstanceId(caseInstanceId); assertEquals(2, query.count()); assertEquals(2, query.list().size()); for (HistoricTaskInstance task : query.list()) {
763764765766767768769770771772773
} public void testQueryByInvalidCaseInstanceId() { HistoricTaskInstanceQuery query = historyService.createHistoricTaskInstanceQuery(); query.caseInstanceId("invalid"); assertEquals(0, query.count()); assertEquals(0, query.list().size()); assertNull(query.singleResult());
769770771772773774775776777778779
assertEquals(0, query.count()); assertEquals(0, query.list().size()); assertNull(query.singleResult()); query.caseInstanceId(null); assertEquals(0, query.count()); assertEquals(0, query.list().size()); assertNull(query.singleResult());