public void execute() {
    execute(TIMEOUT);
  }
@Test
  public void should_timeout() {
    Block block = Block.builder()
      .setBlockHash(new ByteArray("AAAABBBBCCCC"))
      .setResourceId(batchComponent1.key())
      .build();
    index.insert(batchComponent1, Collections.singletonList(block));
    when(executorService.submit(ArgumentMatchers.any(Callable.class))).thenReturn(new CompletableFuture());
    executor.execute(1);

    readDuplications(0);
    assertThat(logTester.logs(Level.WARN))
      .usingElementComparator((l, r) -> l.matches(r) ? 0 : 1)
      .containsOnly(
        "Timeout during detection of duplications for .*Foo.php");
  }