static TimeoutPolicy timeoutXTimes(final int times) {
      final AtomicInteger timeouts = new AtomicInteger(times);
      return () -> {
        if (timeouts.get() <= 0) {
          return false;
        }
        timeouts.decrementAndGet();
        return true;
      };
    }
Create a timeout policy that timeouts x times

@param times the number of timeouts
@return the timeout policy
testutil/src/main/java/org/hyperledger/besu/testutil/DeterministicEthScheduler.java