### Question:
Amount { public static double maxValue() { return 9E13; } @SuppressWarnings("unused") private  Amount();  Amount(final int euros, final int cents);  Amount(final double euros); static double maxValue(); static double minValue(); long getCents(); Amount plus(final Amount other); @Override boolean equals(final Object other); @Override int hashCode(); int compareTo(final Amount other); Amount minus(final Amount other); Amount times(final double factor); double toDouble(); String toString(); static final Amount ZERO; }### Answer:
@Test public void outsideRangeConstruction(){ final double overgreatValue = Amount.maxValue() + 0.01; try{ new Amount(overgreatValue); fail("Amount.RangeExc expected"); }catch(Amount.RangeExc expected){} try{ new Amount(-overgreatValue); fail("Amount.RangeExc expected"); }catch(Amount.RangeExc expected){} }