### Question:
BatchLimitBackoffPolicy implements BackoffPolicy<T> { @Override public boolean shouldApply(T request) { LOG.debug("batchesInFlight: {}, maxBatchesInFlight: {}", batchesInFlight.get(), maxBatchesInFlight); return batchesInFlight.get() >= maxBatchesInFlight; } BatchLimitBackoffPolicy(int maxBatchesInFlight); @Override boolean shouldApply(T request); @Override void register(T request); @Override void deregister(T request);  }### Answer:
@Test public void shouldApplyReturnsFalseIfBatchesInFlightLowerThanConfigured() { BackoffPolicy<Object> policy = new BatchLimitBackoffPolicy<>(1); boolean result = policy.shouldApply(null); assertFalse(result); }