Search in sources :

Example 26 with HistoricCaseInstanceQuery

use of org.camunda.bpm.engine.history.HistoricCaseInstanceQuery in project camunda-bpm-platform by camunda.

the class HistoricCaseInstanceTest method testQueryByInvalidSubCaseInstanceId.

public void testQueryByInvalidSubCaseInstanceId() {
    HistoricCaseInstanceQuery query = historyService.createHistoricCaseInstanceQuery();
    query.subCaseInstanceId("invalid");
    assertEquals(0, query.count());
    assertEquals(0, query.list().size());
    query.caseInstanceId(null);
    assertEquals(0, query.count());
    assertEquals(0, query.list().size());
}
Also used : HistoricCaseInstanceQuery(org.camunda.bpm.engine.history.HistoricCaseInstanceQuery)

Aggregations

HistoricCaseInstanceQuery (org.camunda.bpm.engine.history.HistoricCaseInstanceQuery)26 HistoricCaseInstance (org.camunda.bpm.engine.history.HistoricCaseInstance)7 Deployment (org.camunda.bpm.engine.test.Deployment)7 Response (com.jayway.restassured.response.Response)2 AbstractRestServiceTest (org.camunda.bpm.engine.rest.AbstractRestServiceTest)2 Matchers.containsString (org.hamcrest.Matchers.containsString)2 Test (org.junit.Test)2 InOrder (org.mockito.InOrder)2 ArrayList (java.util.ArrayList)1 HashMap (java.util.HashMap)1 CountResultDto (org.camunda.bpm.engine.rest.dto.CountResultDto)1 HistoricCaseInstanceDto (org.camunda.bpm.engine.rest.dto.history.HistoricCaseInstanceDto)1