public void addPartition(RangePartition p) {
        if (p instanceof RangeEdgePartition) {
            edgePartitions.add((RangeEdgePartition)p);
        } else {
            partitions.add(p);
        }
    }
@Test
    void requireThatRangePartitionsCanBeAdded() {
        FeatureRange range = new FeatureRange("foo", 10L, 22L);
        range.addPartition(new RangePartition("foo=10-19"));
        range.addPartition(new RangePartition("foo", 0, 0x8000000000000000L, true));
        range.addPartition(new RangeEdgePartition("foo=20", 20, 0, 2));
        assertEquals("foo in [10..22 (foo=20+[..2],foo=10-19,foo=-9223372036854775808-0)]", range.toString());
    }