@Test
public void testDecayedCountsWithClockIncrementSmallerThanRescaleThreshold()
{

    int targetAgeInSeconds = (int) (QuantileDigest.RESCALE_THRESHOLD_SECONDS - 1);
    TestingTicker ticker = new TestingTicker();
    QuantileDigest digest = new QuantileDigest(1,
            ExponentialDecay.computeAlpha(0.5, targetAgeInSeconds), ticker);
    addAll(digest, asList(0, 1, 2, 3, 4, 5, 6, 7, 8, 9));
    ticker.elapseTime(targetAgeInSeconds, TimeUnit.SECONDS);
    addAll(digest, asList(10, 11, 12, 13, 14, 15, 16, 17, 18, 19));
    assertEquals(digest.getCount(), 15.0);
}