public FluentBackoff withMaxCumulativeBackoff(Duration maxCumulativeBackoff) {
    checkArgument(
        maxCumulativeBackoff.isLongerThan(Duration.ZERO),
        "maxCumulativeBackoff %s must be at least 1 millisecond",
        maxCumulativeBackoff);
    return new FluentBackoff(
        exponent,
        initialBackoff,
        maxBackoff,
        maxCumulativeBackoff,
        maxRetries,
        throttledTimeCounter);
  }
@Test
  public void testInvalidCumulativeBackoff() {
    thrown.expect(IllegalArgumentException.class);
    thrown.expectMessage("maxCumulativeBackoff PT-0.002S must be at least 1 millisecond");
    defaultBackoff.withMaxCumulativeBackoff(Duration.millis(-2));
  }