catch (JPOXUserException ue)
{
Throwable[] nested = ue.getNestedExceptions();
assertEquals(nested.length, 1);
assertEquals(nested[0].getClass(), InvalidPrimaryKeyException.class);
InvalidPrimaryKeyException ipke = (InvalidPrimaryKeyException)nested[0];
assertEquals("019004", ipke.getMessageKey());
}
catch (Throwable e)
{
e.printStackTrace();
fail(e.getClass().getName() + ": " + e.getMessage());