@Test public void testSetValueBadCurrencyCode() { try { iSOAmount.setValue("X23456789012"); fail("expected exception"); } catch (ISOException e) { assertThat(e.getMessage(), is("For input string: \"X23\"")); } }
@Test public void testSetValueBadLength() { try { iSOAmount.setValue("1234"); fail("expected invalid length ISOException"); } catch (ISOException e) { assertThat(e.getMessage(), is("ISOAmount invalid length 4")); } }