use of gov.ca.cwds.data.persistence.cms.LongText in project API by ca-cwds.
the class LongTextDaoIT method testCreateExistingEntityException.
@Override
@Test
public void testCreateExistingEntityException() throws Exception {
thrown.expect(EntityExistsException.class);
gov.ca.cwds.rest.api.domain.cms.LongText vdlt = validDomainLongText();
LongText longText = new LongText(id, vdlt.getCountySpecificCode(), vdlt.getTextDescription());
longTextDao.create(longText);
}
use of gov.ca.cwds.data.persistence.cms.LongText in project API by ca-cwds.
the class LongTextDaoIT method testFindEntityNotFoundException.
@Override
@Test
public void testFindEntityNotFoundException() throws Exception {
LongText found = longTextDao.find("9999999ZZZ");
assertThat(found, is(nullValue()));
}
use of gov.ca.cwds.data.persistence.cms.LongText in project API by ca-cwds.
the class LongTextDaoIT method testCreate.
/**
* Create JUnit test
*/
@Override
@Test
public void testCreate() throws Exception {
gov.ca.cwds.rest.api.domain.cms.LongText vdlt = validDomainLongText();
LongText longText = new LongText("ABC1234567", vdlt.getCountySpecificCode(), vdlt.getTextDescription());
LongText create = longTextDao.create(longText);
assertThat(longText, is(create));
}
use of gov.ca.cwds.data.persistence.cms.LongText in project API by ca-cwds.
the class LongTextDaoIT method testFind.
@Override
@Test
public void testFind() throws Exception {
LongText found = longTextDao.find(id);
assertThat(found.getId(), is(equalTo(id)));
}
use of gov.ca.cwds.data.persistence.cms.LongText in project API by ca-cwds.
the class LongTextDaoIT method testUpdate.
@Override
@Test
public void testUpdate() throws Exception {
gov.ca.cwds.rest.api.domain.cms.LongText vdlt = validDomainLongText();
LongText longText = new LongText(id, vdlt.getCountySpecificCode(), vdlt.getTextDescription());
LongText updated = longTextDao.update(longText);
assertThat(longText, is(updated));
}
Aggregations