### Question:
IntegerRange implements Range<Integer> { @Override public Integer getEnd() { return end; } IntegerRange(Integer start, Integer end);  IntegerRange(Integer start, Integer end, Integer step); @Override boolean contains(Object other); @Override Integer getStart(); @Override Integer getEnd(); @Override Integer getStep(); @Override Iterator<Integer> iterator();  }### Answer:
@Test public void shouldDefaultToAnEndOfIntegerMaxIfTheStepSizeIsPositive() throws Exception { Range<Integer> range = new IntegerRange(0, null, 1); Integer end = range.getEnd(); assertThat(end, is(Integer.MAX_VALUE)); }
@Test public void shouldDefaultToAnEndOfIntegerMinIfTheStepSizeIsNegative() throws Exception { Range<Integer> range = new IntegerRange(0, null, -1); Integer end = range.getEnd(); assertThat(end, is(Integer.MIN_VALUE)); }
@Test public void shouldReturnTheSpecifiedEnd() throws Exception { Range<Integer> range = new IntegerRange(0, 10, 1); Integer end = range.getEnd(); assertThat(end, is(10)); }