Ejemplo n.º 1
0
  @Override
  public Publisher<Long> createPublisher(long elements) {
    if (!DependencyUtils.hasJdk9Flow()) {
      throw new SkipException("no jdk 9 classes found");
    }

    SubmissionPublisher<Long> pub = new SubmissionPublisher<>();
    Timers.global().schedule(pub::submit, 50, TimeUnit.MILLISECONDS);
    return Publishers.convert(pub);
  }
Ejemplo n.º 2
0
 @BeforeTest
 public void before() {
   Timers.global();
 }