public void testCompressedLongSequence() throws IOException {
ByteArrayDataOutputStream out=new ByteArrayDataOutputStream(1024);
long[] numbers={0, 1, 100, 322649, Long.MAX_VALUE-1000};
for(long i: numbers)
Bits.writeLongSequence(i, i + 100,out);
ByteArrayDataInputStream in=new ByteArrayDataInputStream(out.buffer());
for(long i: numbers) {
long[] seq=Bits.readLongSequence(in);
assert Arrays.equals(seq, new long[]{i, i+100});
}
}