Search in sources :

Example 11 with CountyOwnership

use of gov.ca.cwds.data.persistence.cms.CountyOwnership in project API by ca-cwds.

the class CountyOwnershipDaoIT method testFind.

@Override
@Test
public void testFind() throws Exception {
    String entityId = "AaNli340MV";
    CountyOwnership found = countyOwnershipDao.find(entityId);
    assertThat(found.getEntityId(), is(equalTo(entityId)));
}
Also used : CountyOwnership(gov.ca.cwds.data.persistence.cms.CountyOwnership) Test(org.junit.Test)

Example 12 with CountyOwnership

use of gov.ca.cwds.data.persistence.cms.CountyOwnership in project API by ca-cwds.

the class CountyOwnershipDaoIT method testCreate.

@Override
@Test
public void testCreate() throws Exception {
    CountyOwnership countyOwnership = new CountyOwnership("ABC1234567", "C", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", "N", null);
    CountyOwnership created = countyOwnershipDao.create(countyOwnership);
    assertThat(created, is(countyOwnership));
}
Also used : CountyOwnership(gov.ca.cwds.data.persistence.cms.CountyOwnership) Test(org.junit.Test)

Example 13 with CountyOwnership

use of gov.ca.cwds.data.persistence.cms.CountyOwnership in project API by ca-cwds.

the class CountyOwnershipDaoIT method testFindEntityNotFoundException.

@Override
@Test
public void testFindEntityNotFoundException() throws Exception {
    CountyOwnership found = countyOwnershipDao.find("9999999ZZZ");
    assertThat(found, is(nullValue()));
}
Also used : CountyOwnership(gov.ca.cwds.data.persistence.cms.CountyOwnership) Test(org.junit.Test)

Aggregations

CountyOwnership (gov.ca.cwds.data.persistence.cms.CountyOwnership)13 Test (org.junit.Test)10 ReferralClient (gov.ca.cwds.rest.api.domain.cms.ReferralClient)3 InvocationOnMock (org.mockito.invocation.InvocationOnMock)3 Client (gov.ca.cwds.data.persistence.cms.Client)1 TriggerTableException (gov.ca.cwds.data.rules.TriggerTableException)1 InvocationTargetException (java.lang.reflect.InvocationTargetException)1 Method (java.lang.reflect.Method)1