@Test
public void testMinus() {

    Range range;
    ImmutableRangeSet.Builder builder;
    Interval.Difference difference;
    
    difference = c.minus(a);
    range = Range.openClosed(4, 10);
    builder = ImmutableRangeSet.builder().add(range);
    assertEquals(difference.getRanges(), builder.build());
    assertEquals(difference.getDimension(), 1);
    
    difference = a.minus(a);
    builder = ImmutableRangeSet.builder(); 
    assertEquals(difference.getRanges(), builder.build());
    assertEquals(difference.getDimension(), 1);
    
    difference = a.minus(b);
    range = a.toRange();
    builder = ImmutableRangeSet.builder().add(range);
    assertEquals(difference.getRanges(), builder.build());
    assertEquals(difference.getDimension(), 1);
    
    difference = b.minus(a);
    range = b.toRange();
    builder = ImmutableRangeSet.builder().add(range);
    assertEquals(difference.getRanges(), builder.build());
    assertEquals(difference.getDimension(), 1);
    
    difference = c.minus(x);
    range = Range.closedOpen(2, 5);
    builder = ImmutableRangeSet.builder().add(range);
    range = Range.openClosed(7, 10);
    builder.add(range);
    assertEquals(difference.getRanges(), builder.build());
    assertEquals(difference.getDimension(), 1);
    
    difference = x.minus(c);
    builder = ImmutableRangeSet.builder();
    assertEquals(difference.getRanges(), builder.build());
    assertEquals(difference.getDimension(), 1);
}