use of gov.ca.cwds.data.legacy.cms.entity.ClientRelationship in project api-core by ca-cwds.
the class BaseDocToolRulesChildClientRelationshipTest method getRelationship.
protected ClientRelationship getRelationship(LocalDate startDate, LocalDate endDate) {
ClientRelationship clientRelationship = new ClientRelationship();
clientRelationship.setStartDate(startDate);
clientRelationship.setEndDate(endDate);
Client client = new Client();
client.setIdentifier(PRIMARY_ID);
Client clientSecondary = new Client();
clientSecondary.setIdentifier(SECONDARY_ID);
clientRelationship.setPrimaryClient(client);
clientRelationship.setSecondaryClient(clientSecondary);
return clientRelationship;
}
use of gov.ca.cwds.data.legacy.cms.entity.ClientRelationship in project api-core by ca-cwds.
the class R00755Test method testEndDateNull.
@Test
public void testEndDateNull() throws Exception {
LocalDate date = LocalDate.of(2003, 03, 01);
ClientRelationship entity = getClientRelationship(date, null);
awareDTO.setEntity(entity);
checkRuleSatisfied(RULE_NAME);
}
use of gov.ca.cwds.data.legacy.cms.entity.ClientRelationship in project api-core by ca-cwds.
the class R00755Test method startDateLtEndDate.
@Test
public void startDateLtEndDate() throws Exception {
ClientRelationship entity = getClientRelationship(LocalDate.of(1999, 03, 01), LocalDate.of(2000, 02, 02));
awareDTO.setEntity(entity);
checkRuleSatisfied(RULE_NAME);
}
use of gov.ca.cwds.data.legacy.cms.entity.ClientRelationship in project api-core by ca-cwds.
the class R00755Test method getClientRelationship.
private ClientRelationship getClientRelationship(LocalDate startDate, LocalDate endDate) {
ClientRelationship entity = new ClientRelationship();
entity.setStartDate(startDate);
entity.setEndDate(endDate);
return entity;
}
use of gov.ca.cwds.data.legacy.cms.entity.ClientRelationship in project api-core by ca-cwds.
the class R00755Test method startDateGtEndDate.
@Test
public void startDateGtEndDate() throws Exception {
ClientRelationship entity = getClientRelationship(LocalDate.of(2001, 01, 01), LocalDate.of(2000, 02, 02));
awareDTO.setEntity(entity);
checkRuleViolatedOnce(RULE_NAME);
}
Aggregations