Width { @Override public String toString() { return "Width{" + "min=" + min + ", max=" + max + '}'; } Width(final int min, final int max); Width toMin(); Width toMax(); static Width ofString(final String string); Width adjust(final Width that); Width add(final Width that); Width subtract(final Width that); int getMin(); int getMax(); @Override String toString(); static final Width ZERO; }
@Test public void testToString() { final Width a = new Width(13, 42); assertEquals("Width{min=13, max=42}", a.toString()); }