use of com.palantir.atlasdb.cassandra.backup.CqlMetadata in project atlasdb by palantir.
the class CassandraRepairEteTest method testTokenRangeCoversFullRing.
@Test
public void testTokenRangeCoversFullRing() {
CqlMetadata cqlMetadata = new CqlMetadata(cluster.getMetadata());
Set<Range<LightweightOppToken>> tokenRanges = cqlMetadata.getTokenRanges();
// Turning this into a RangeSet should give the complete range (-inf, +inf)
RangeSet<LightweightOppToken> fullTokenRing = tokenRanges.stream().collect(toImmutableRangeSet());
assertThat(fullTokenRing.asRanges()).containsExactly(Range.all());
}
Aggregations