vertx/src/test/java/eu/internetofus/common/vertx/RepositoryIT.java
/**
   * Should not update document because query is not valid.
   *
   * @param vertx       event bus to use.
   * @param testContext context for the test.
   */
Should not update document because query is not valid.
@param vertx       event bus to use.
@param testContext context for the test.
Should not update document because query is not valid . @param vertx event bus to use . @param testContext context for the test .
@Test
  public void shouldNotUpdateDocumentBecauseQueryIsNotValid(final Vertx vertx, final VertxTestContext testContext) {
    final var repository = new Repository(vertx, pool, "schemaVersion");
    testContext.assertFailure(repository.updateOneDocument(TEN_DUMMY_COLLECTION,
        new JsonObject().put("index", new JsonObject().put("$undefinedAction", -1)), new JsonObject().putNull("index")))
        .onFailure(error -> testContext.completeNow());
  }
@ Test public void shouldNotUpdateDocumentBecauseQueryIsNotValid ( final Vertx vertx , final VertxTestContext testContext ) { final var repository = new Repository ( vertx , pool , "schemaVersion" ) ; testContext . assertFailure ( repository . updateOneDocument ( TEN_DUMMY_COLLECTION , new JsonObject ( ) . put ( "index" , new JsonObject ( ) . put ( "$undefinedAction" , - 1 ) ) , new JsonObject ( ) . putNull ( "index" ) ) ) . onFailure ( error -> testContext . completeNow ( ) ) ; }
Should not update document because query is not valid.
Should not update document because query is not valid .