Search in sources :

Example 11 with DecisionRequirementsDefinitionQuery

use of org.camunda.bpm.engine.repository.DecisionRequirementsDefinitionQuery in project camunda-bpm-platform by camunda.

the class DecisionRequirementsDefinitionQueryTest method queryByDecisionRequirementsDefinitionKey.

@Test
public void queryByDecisionRequirementsDefinitionKey() {
    DecisionRequirementsDefinitionQuery query = repositoryService.createDecisionRequirementsDefinitionQuery();
    assertThat(query.decisionRequirementsDefinitionKey("notExisting").count(), is(0L));
    assertThat(query.decisionRequirementsDefinitionKey("score").count(), is(1L));
    assertThat(query.singleResult().getKey(), is("score"));
}
Also used : DecisionRequirementsDefinitionQuery(org.camunda.bpm.engine.repository.DecisionRequirementsDefinitionQuery) Test(org.junit.Test)

Example 12 with DecisionRequirementsDefinitionQuery

use of org.camunda.bpm.engine.repository.DecisionRequirementsDefinitionQuery in project camunda-bpm-platform by camunda.

the class DecisionRequirementsDefinitionQueryTest method queryByDecisionRequirementsDefinitionCategory.

@Test
public void queryByDecisionRequirementsDefinitionCategory() {
    DecisionRequirementsDefinitionQuery query = repositoryService.createDecisionRequirementsDefinitionQuery();
    assertThat(query.decisionRequirementsDefinitionCategory("notExisting").count(), is(0L));
    assertThat(query.decisionRequirementsDefinitionCategory("test-drd-1").count(), is(1L));
    assertThat(query.singleResult().getKey(), is("score"));
}
Also used : DecisionRequirementsDefinitionQuery(org.camunda.bpm.engine.repository.DecisionRequirementsDefinitionQuery) Test(org.junit.Test)

Example 13 with DecisionRequirementsDefinitionQuery

use of org.camunda.bpm.engine.repository.DecisionRequirementsDefinitionQuery in project camunda-bpm-platform by camunda.

the class DecisionRequirementsDefinitionQueryTest method queryByDecisionRequirementsDefinitionId.

@Test
public void queryByDecisionRequirementsDefinitionId() {
    DecisionRequirementsDefinitionQuery query = repositoryService.createDecisionRequirementsDefinitionQuery();
    assertThat(query.decisionRequirementsDefinitionId("notExisting").count(), is(0L));
    assertThat(query.decisionRequirementsDefinitionId(decisionRequirementsDefinitionId).count(), is(1L));
    assertThat(query.singleResult().getKey(), is("score"));
}
Also used : DecisionRequirementsDefinitionQuery(org.camunda.bpm.engine.repository.DecisionRequirementsDefinitionQuery) Test(org.junit.Test)

Example 14 with DecisionRequirementsDefinitionQuery

use of org.camunda.bpm.engine.repository.DecisionRequirementsDefinitionQuery in project camunda-bpm-platform by camunda.

the class DecisionRequirementsDefinitionQueryTest method queryByResourceNameLikeEscape.

@Test
public void queryByResourceNameLikeEscape() {
    DecisionRequirementsDefinitionQuery query = repositoryService.createDecisionRequirementsDefinitionQuery();
    assertThat(query.decisionRequirementsDefinitionResourceNameLike("%z\\_.%").count(), is(1L));
}
Also used : DecisionRequirementsDefinitionQuery(org.camunda.bpm.engine.repository.DecisionRequirementsDefinitionQuery) Test(org.junit.Test)

Example 15 with DecisionRequirementsDefinitionQuery

use of org.camunda.bpm.engine.repository.DecisionRequirementsDefinitionQuery in project camunda-bpm-platform by camunda.

the class DecisionRequirementsDefinitionQueryTest method queryByDeploymentId.

@Test
public void queryByDeploymentId() {
    DecisionRequirementsDefinitionQuery query = repositoryService.createDecisionRequirementsDefinitionQuery();
    assertThat(query.deploymentId("notExisting").count(), is(0L));
    assertThat(query.deploymentId(firstDeploymentId).count(), is(2L));
    assertThat(query.deploymentId(secondDeploymentId).count(), is(1L));
}
Also used : DecisionRequirementsDefinitionQuery(org.camunda.bpm.engine.repository.DecisionRequirementsDefinitionQuery) Test(org.junit.Test)

Aggregations

DecisionRequirementsDefinitionQuery (org.camunda.bpm.engine.repository.DecisionRequirementsDefinitionQuery)37 Test (org.junit.Test)31 DecisionRequirementsDefinition (org.camunda.bpm.engine.repository.DecisionRequirementsDefinition)9 Deployment (org.camunda.bpm.engine.test.Deployment)4 InputStream (java.io.InputStream)2 ProcessEngine (org.camunda.bpm.engine.ProcessEngine)2 DecisionRequirementsDefinitionQueryDto (org.camunda.bpm.engine.rest.dto.repository.DecisionRequirementsDefinitionQueryDto)2 ArrayList (java.util.ArrayList)1 CountResultDto (org.camunda.bpm.engine.rest.dto.CountResultDto)1 DecisionRequirementsDefinitionDto (org.camunda.bpm.engine.rest.dto.repository.DecisionRequirementsDefinitionDto)1