use of org.kie.workbench.common.stunner.bpmn.definition.property.reassignment.ReassignmentValue in project kie-wb-common by kiegroup.
the class ReassignmentValueValidatorTest method testIntOverflowExpiresAtReassignmentValue.
@Test
public void testIntOverflowExpiresAtReassignmentValue() {
ReassignmentValue value = new ReassignmentValue();
value.setDuration("2147483648d");
boolean result = validator.isValid(value, context);
assertFalse(result);
assertFalse(errorMessages.isEmpty());
}
use of org.kie.workbench.common.stunner.bpmn.definition.property.reassignment.ReassignmentValue in project kie-wb-common by kiegroup.
the class ReassignmentValueValidatorTest method test2DigExpiresAtReassignmentValue.
@Test
public void test2DigExpiresAtReassignmentValue() {
ReassignmentValue value = new ReassignmentValue();
value.setDuration("11d");
boolean result = validator.isValid(value, context);
assertTrue(result);
assertTrue(errorMessages.isEmpty());
}
use of org.kie.workbench.common.stunner.bpmn.definition.property.reassignment.ReassignmentValue in project kie-wb-common by kiegroup.
the class ReassignmentValueValidatorTest method test4DigExpiresAtReassignmentValue.
@Test
public void test4DigExpiresAtReassignmentValue() {
ReassignmentValue value = new ReassignmentValue();
value.setDuration("1111d");
boolean result = validator.isValid(value, context);
assertTrue(result);
}
use of org.kie.workbench.common.stunner.bpmn.definition.property.reassignment.ReassignmentValue in project kie-wb-common by kiegroup.
the class ReassignmentValueValidatorTest method testIntMaxExpiresAtReassignmentValue.
@Test
public void testIntMaxExpiresAtReassignmentValue() {
ReassignmentValue value = new ReassignmentValue();
value.setDuration("2147483647d");
boolean result = validator.isValid(value, context);
assertTrue(result);
assertTrue(errorMessages.isEmpty());
}
use of org.kie.workbench.common.stunner.bpmn.definition.property.reassignment.ReassignmentValue in project kie-wb-common by kiegroup.
the class ReassignmentPropertyWriterTest method getReassignmentValue.
private ReassignmentValue getReassignmentValue(String type) {
List<String> users = new ArrayList<>();
users.add("AAA");
users.add("BBB");
List<String> groups = new ArrayList<>();
users.add("G1");
users.add("G2");
ReassignmentValue value = new ReassignmentValue();
value.setType(type);
value.setUsers(users);
value.setGroups(groups);
value.setDuration("1d");
return value;
}
Aggregations