use of siena.base.test.model.PersonUUID in project siena by mandubian.
the class BaseTestNoAutoInc_1_CRUD method testGetUUID.
public void testGetUUID() {
PersonUUID curie = getPersonUUID(UUID_CURIE.id);
assertEquals(UUID_CURIE, curie);
}
use of siena.base.test.model.PersonUUID in project siena by mandubian.
the class BaseTestNoAutoInc_1_CRUD method testUpdateUUID.
public void testUpdateUUID() {
PersonUUID curie = getPersonUUID(UUID_CURIE.id);
curie.lastName = "Sklodowska–Curie";
pm.update(curie);
PersonUUID curie2 = getPersonUUID(UUID_CURIE.id);
assertEquals(curie2, curie);
}
use of siena.base.test.model.PersonUUID in project siena by mandubian.
the class BaseTestNoAutoInc_1_CRUD method testDeleteUUID.
public void testDeleteUUID() {
PersonUUID curie = getPersonUUID(UUID_CURIE.id);
pm.delete(curie);
List<PersonUUID> people = queryPersonUUIDOrderBy("n", 0, false).fetch();
assertNotNull(people);
assertEquals(2, people.size());
assertEquals(UUID_TESLA, people.get(0));
assertEquals(UUID_EINSTEIN, people.get(1));
}
use of siena.base.test.model.PersonUUID in project siena by mandubian.
the class BaseTest method testDeleteObjectNotFound.
public void testDeleteObjectNotFound() {
try {
PersonUUID p = new PersonUUID();
pm.delete(p);
fail();
} catch (Exception e) {
System.out.println("Everything is OK");
}
}
use of siena.base.test.model.PersonUUID in project siena by mandubian.
the class BaseTest method testUpdateUUID.
public void testUpdateUUID() {
PersonUUID curie = getPersonUUID(UUID_CURIE.id);
curie.lastName = "Sklodowska–Curie";
pm.update(curie);
PersonUUID curie2 = getPersonUUID(UUID_CURIE.id);
assertEquals(curie2, curie);
}
Aggregations