vertx/src/test/java/eu/internetofus/common/vertx/AbstractPersistenceVerticleTest.java
/**
   * Check that not start because can not register repositories.
   *
   * @param testContext context of the test.
   *
   * @throws Exception If the verticle cannot be started.
   */
Check that not start because can not register repositories.
@param testContext context of the test.

@throws Exception If the verticle cannot be started.
Check that not start because can not register repositories . @param testContext context of the test . @throws Exception If the verticle cannot be started .
@Test
  public void shouldNotStartBecauseFailToRegisterRepositoriesFor(final VertxTestContext testContext) throws Exception {
    doReturn(Future.failedFuture("Cannot register")).when(this.verticle).registerRepositoriesFor(any());
    final Promise<Void> startPromise = Promise.promise();
    this.verticle.start(startPromise);
    startPromise.future().onComplete(testContext.failing(error -> testContext.completeNow()));
  }
@ Test public void shouldNotStartBecauseFailToRegisterRepositoriesFor ( final VertxTestContext testContext ) throws Exception { doReturn ( Future . failedFuture ( "Cannot register" ) ) . when ( this . verticle ) . registerRepositoriesFor ( any ( ) ) ; final Promise < Void > startPromise = Promise . promise ( ) ; this . verticle . start ( startPromise ) ; startPromise . future ( ) . onComplete ( testContext . failing ( error -> testContext . completeNow ( ) ) ) ; }
Check that not start because can not register repositories.
Check that not start because can not register repositories .