vertx/src/test/java/eu/internetofus/common/vertx/RepositoryIT.java
/**
   * Should not aggregate page because query is wrong.
   *
   * @param vertx       event bus to use.
   * @param testContext context for the test.
   */
Should not aggregate page because query is wrong.
@param vertx       event bus to use.
@param testContext context for the test.
Should not aggregate page because query is wrong . @param vertx event bus to use . @param testContext context for the test .
@Test
  public void shouldNotAggregatePageObjectBecauseQueryIsNotValid(final Vertx vertx,
      final VertxTestContext testContext) {
    final var repository = new Repository(vertx, pool, "schemaVersion");
    final var query = new JsonObject().put("$undefinedAction", -1);
    final var order = new JsonObject();
    repository.aggregatePageObject(EMPTY_COLLECTION, query, order, 0, 10, "models")
        .onComplete(testContext.failing(error -> testContext.completeNow()));
  }
@ Test public void shouldNotAggregatePageObjectBecauseQueryIsNotValid ( final Vertx vertx , final VertxTestContext testContext ) { final var repository = new Repository ( vertx , pool , "schemaVersion" ) ; final var query = new JsonObject ( ) . put ( "$undefinedAction" , - 1 ) ; final var order = new JsonObject ( ) ; repository . aggregatePageObject ( EMPTY_COLLECTION , query , order , 0 , 10 , "models" ) . onComplete ( testContext . failing ( error -> testContext . completeNow ( ) ) ) ; }
Should not aggregate page because query is wrong.
Should not aggregate page because query is wrong .