assertEquals("trivially expected only one test in the matrix", 1, matrix.getTests().size());
final List<Allocation> allocations = matrix.getTests().values().iterator().next().getAllocations();
assertEquals("trivially expected only one allocation in the test (same as source)", 1, allocations.size());
final List<Range> ranges = allocations.iterator().next().getRanges();
assertEquals("Expected the ranges to be reduced from 3 to 1, since only the fallback value is now present", 1, ranges.size());
final Range onlyRange = ranges.iterator().next();
assertEquals("Should have adopted the fallback value from the test spec", onlyRange.getBucketValue(), testSpecification.getFallbackValue());
assertEquals("Trivially should have been set to 100% fallback", 1.0, onlyRange.getLength(), 0.005);
}
{
final Map<String, ConsumableTestDefinition> tests = Maps.newHashMap();
// Allocation of bucketValue=2 is == 0
tests.put(TEST_A, constructDefinition(buckets, fromCompactAllocationFormat("0:0.5,1:0.5,2:0")));