diff --git a/002-quarkus-all-extensions/src/test/java/io/quarkus/qe/core/containers/MongoTestResource.java b/002-quarkus-all-extensions/src/test/java/io/quarkus/qe/core/containers/MongoTestResource.java index 6ef7ecac..8250fbfc 100644 --- a/002-quarkus-all-extensions/src/test/java/io/quarkus/qe/core/containers/MongoTestResource.java +++ b/002-quarkus-all-extensions/src/test/java/io/quarkus/qe/core/containers/MongoTestResource.java @@ -19,7 +19,7 @@ public class MongoTestResource implements QuarkusTestResourceLifecycleManager { @Override public Map start() { - resource = new GenericContainer<>("quay.io/bitnami/mongodb:4.0.23"); + resource = new GenericContainer<>("docker.io/mongo:4.0.23"); resource.waitingFor(new LogMessageWaitStrategy().withRegEx("(?i).*waiting for connections.*")); resource.addExposedPort(PORT); resource.start(); diff --git a/013-quarkus-oidc-restclient/src/main/resources/application.properties b/013-quarkus-oidc-restclient/src/main/resources/application.properties index 6947c991..d5815fe2 100644 --- a/013-quarkus-oidc-restclient/src/main/resources/application.properties +++ b/013-quarkus-oidc-restclient/src/main/resources/application.properties @@ -42,3 +42,5 @@ io.quarkus.qe.ping.clients.TokenPropagationPongClient/mp-rest/url=http://localho #OpenAPI quarkus.smallrye-openapi.store-schema-directory=target/generated/jax-rs/ +quarkus.smallrye-openapi.info-title=Custom API Title +quarkus.smallrye-openapi.info-version=1.0.1 \ No newline at end of file diff --git a/013-quarkus-oidc-restclient/src/test/java/io/quarkus/qe/OpenApiTest.java b/013-quarkus-oidc-restclient/src/test/java/io/quarkus/qe/OpenApiTest.java index 1639d6b3..68713553 100644 --- a/013-quarkus-oidc-restclient/src/test/java/io/quarkus/qe/OpenApiTest.java +++ b/013-quarkus-oidc-restclient/src/test/java/io/quarkus/qe/OpenApiTest.java @@ -37,7 +37,7 @@ public class OpenApiTest { private static final Path JSON_FILE_NAME_FULL_PATH = Paths.get(directory + JSON_FILE_NAME); private static final String EXPECTED_TAGS = "[{\"name\":\"Ping\",\"description\":\"Ping API\"},{\"name\":\"Pong\",\"description\":\"Pong API\"}]"; - private static final String EXPECTED_INFO = "{\"title\":\"Generated API\",\"version\":\"1.0\"}"; + private static final String EXPECTED_INFO = "{\"title\":\"Custom API Title\",\"version\":\"1.0.1\"}"; // QUARKUS-716 @Test diff --git a/013-quarkus-oidc-restclient/src/test/java/io/quarkus/qe/OpenApiTestIT.java b/013-quarkus-oidc-restclient/src/test/java/io/quarkus/qe/OpenApiTestIT.java index 65d10ce2..6f10e5f7 100644 --- a/013-quarkus-oidc-restclient/src/test/java/io/quarkus/qe/OpenApiTestIT.java +++ b/013-quarkus-oidc-restclient/src/test/java/io/quarkus/qe/OpenApiTestIT.java @@ -4,13 +4,5 @@ @NativeImageTest public class OpenApiTestIT extends OpenApiTest { - // quarkus-maven-plugin:build adjusts OpenAPI info - // see https://github.com/quarkusio/quarkus/pull/19148/commits/8fe04d7a06aa976e0b85d72864578f3ab834a27a - // surefire is executed before quarkus-maven-plugin:build and thus the message there is the generic one - private static final String QUARKUS_ADJUSTED_INFO = "{\"title\":\"013-quarkus-oidc-restclient API\",\"version\":\"1.0.0-SNAPSHOT\"}"; - @Override - String getExpectedInfo() { - return QUARKUS_ADJUSTED_INFO; - } } diff --git a/014-quarkus-panache-with-transactions-xa/src/test/java/io/quarkus/qe/containers/MySqlDatabaseTestResource.java b/014-quarkus-panache-with-transactions-xa/src/test/java/io/quarkus/qe/containers/MySqlDatabaseTestResource.java index 0c602210..5de0f607 100644 --- a/014-quarkus-panache-with-transactions-xa/src/test/java/io/quarkus/qe/containers/MySqlDatabaseTestResource.java +++ b/014-quarkus-panache-with-transactions-xa/src/test/java/io/quarkus/qe/containers/MySqlDatabaseTestResource.java @@ -26,7 +26,7 @@ public class MySqlDatabaseTestResource implements QuarkusTestResourceLifecycleMa @Override public Map start() { container = new MySQLContainer<>( - DockerImageName.parse("quay.io/bitnami/mysql:5.7.32").asCompatibleSubstituteFor(MYSQL)); + DockerImageName.parse("docker.io/mysql:5.7").asCompatibleSubstituteFor(MYSQL)); container.withUrlParam("currentSchema", DEFAULT_SCHEMA); container.start(); diff --git a/019-quarkus-consul/src/test/java/io/quarkus/qe/containers/ConsulContainer.java b/019-quarkus-consul/src/test/java/io/quarkus/qe/containers/ConsulContainer.java index abd59bbd..750192ee 100644 --- a/019-quarkus-consul/src/test/java/io/quarkus/qe/containers/ConsulContainer.java +++ b/019-quarkus-consul/src/test/java/io/quarkus/qe/containers/ConsulContainer.java @@ -9,7 +9,7 @@ public class ConsulContainer extends GenericContainer { private static final int PORT = 8500; public ConsulContainer() { - super("quay.io/bitnami/consul:1.9.3"); + super("docker.io/consul:1.9.3"); waitingFor(new LogMessageWaitStrategy().withRegEx(".*Synced node info.*\\s")); withStartupTimeout(Duration.ofMillis(60000)); addFixedExposedPort(PORT, PORT); diff --git a/302-quarkus-vertx-jwt/src/test/java/io/quarkus/qe/vertx/resources/RedisResource.java b/302-quarkus-vertx-jwt/src/test/java/io/quarkus/qe/vertx/resources/RedisResource.java index 8700886e..12b5c4e0 100644 --- a/302-quarkus-vertx-jwt/src/test/java/io/quarkus/qe/vertx/resources/RedisResource.java +++ b/302-quarkus-vertx-jwt/src/test/java/io/quarkus/qe/vertx/resources/RedisResource.java @@ -16,7 +16,7 @@ public class RedisResource implements QuarkusTestResourceLifecycleManager { @Override public Map start() { - redisContainer = new GenericContainer(DockerImageName.parse("quay.io/bitnami/redis:6.0")) + redisContainer = new GenericContainer(DockerImageName.parse("docker.io/redis:6.0")) .withEnv("ALLOW_EMPTY_PASSWORD", "yes").withExposedPorts(6379); redisContainer.start(); diff --git a/303-quarkus-vertx-sql/pom.xml b/303-quarkus-vertx-sql/pom.xml index b3307ea1..5264139e 100644 --- a/303-quarkus-vertx-sql/pom.xml +++ b/303-quarkus-vertx-sql/pom.xml @@ -62,6 +62,10 @@ smallrye-mutiny-vertx-web-client test + + org.flywaydb + flyway-mysql + diff --git a/303-quarkus-vertx-sql/src/test/java/io/quarkus/qe/vertx/sql/test/resources/MysqlResource.java b/303-quarkus-vertx-sql/src/test/java/io/quarkus/qe/vertx/sql/test/resources/MysqlResource.java index 48edc95a..b11c8e59 100644 --- a/303-quarkus-vertx-sql/src/test/java/io/quarkus/qe/vertx/sql/test/resources/MysqlResource.java +++ b/303-quarkus-vertx-sql/src/test/java/io/quarkus/qe/vertx/sql/test/resources/MysqlResource.java @@ -16,7 +16,7 @@ public class MysqlResource implements QuarkusTestResourceLifecycleManager { @Override public Map start() { - mysqlContainer = new GenericContainer<>(DockerImageName.parse("quay.io/bitnami/mysql:8.0")) + mysqlContainer = new GenericContainer<>(DockerImageName.parse("docker.io/mysql:8.0")) .withEnv("MYSQL_ROOT_PASSWORD", "test") .withEnv("MYSQL_USER", "test") .withEnv("MYSQL_PASSWORD", "test") @@ -24,7 +24,7 @@ public Map start() { .withExposedPorts(3306); mysqlContainer.waitingFor(new HostPortWaitStrategy()).waitingFor( - Wait.forLogMessage(".*ready for connections.*", 1)).start(); + Wait.forLogMessage(".*ready for connections.*port: 33060.*", 1)).start(); Map config = new HashMap<>(); config.put("quarkus.datasource.mysql.jdbc.url", diff --git a/303-quarkus-vertx-sql/src/test/java/io/quarkus/qe/vertx/sql/test/resources/PostgresqlResource.java b/303-quarkus-vertx-sql/src/test/java/io/quarkus/qe/vertx/sql/test/resources/PostgresqlResource.java index 6fe7040e..dff29b9f 100644 --- a/303-quarkus-vertx-sql/src/test/java/io/quarkus/qe/vertx/sql/test/resources/PostgresqlResource.java +++ b/303-quarkus-vertx-sql/src/test/java/io/quarkus/qe/vertx/sql/test/resources/PostgresqlResource.java @@ -17,7 +17,7 @@ public class PostgresqlResource implements QuarkusTestResourceLifecycleManager { @Override public Map start() { - postgresContainer = new GenericContainer<>(DockerImageName.parse("quay.io/bitnami/postgresql:13.4.0")) + postgresContainer = new GenericContainer<>(DockerImageName.parse("docker.io/postgres:13.6")) .withEnv("POSTGRES_USER", "test") .withEnv("POSTGRES_PASSWORD", "test") .withEnv("POSTGRES_DB", "amadeus") diff --git a/303-quarkus-vertx-sql/src/test/resources/docker-compose.yaml b/303-quarkus-vertx-sql/src/test/resources/docker-compose.yaml index cc9b2701..acac634e 100644 --- a/303-quarkus-vertx-sql/src/test/resources/docker-compose.yaml +++ b/303-quarkus-vertx-sql/src/test/resources/docker-compose.yaml @@ -12,7 +12,7 @@ services: POSTGRES_DB: amadeus mysql: - image: quay.io/bitnami/mysql:5.7.32 + image: docker.io/mysql:5.7.32 hostname: mysql container_name: mysql ports: diff --git a/304-quarkus-vertx-routes/src/test/java/io/quarkus/qe/validation/ValidationOnRequestBodyRouteHandlerTest.java b/304-quarkus-vertx-routes/src/test/java/io/quarkus/qe/validation/ValidationOnRequestBodyRouteHandlerTest.java index d8cf0182..7c142100 100644 --- a/304-quarkus-vertx-routes/src/test/java/io/quarkus/qe/validation/ValidationOnRequestBodyRouteHandlerTest.java +++ b/304-quarkus-vertx-routes/src/test/java/io/quarkus/qe/validation/ValidationOnRequestBodyRouteHandlerTest.java @@ -1,6 +1,6 @@ package io.quarkus.qe.validation; -import static io.quarkus.qe.validation.utils.ValidationAssertions.assertValidationErrorDetails; +import static io.quarkus.qe.validation.utils.ValidationAssertions.assertValidationErrorDetail; import static io.quarkus.qe.validation.utils.ValidationAssertions.assertValidationErrorField; import static io.quarkus.qe.validation.utils.ValidationAssertions.assertValidationErrorStatus; import static io.quarkus.qe.validation.utils.ValidationAssertions.assertValidationErrorTitle; @@ -30,7 +30,7 @@ public void shouldGetValidationErrorWhenRequestFirstCodeIsWrong() { .extract().as(ValidationErrorResponse.class); assertValidationErrorTitle(response); - assertValidationErrorDetails(response); + assertValidationErrorDetail(response); assertValidationErrorStatus(response, HttpStatus.SC_BAD_REQUEST); assertValidationErrorField(response, "validateRequestBody.param.firstCode", "First code must have 3 characters"); } @@ -49,7 +49,7 @@ public void shouldGetValidationErrorsWhenFirstAndSecondCodesAreWrong() { .statusCode(HttpStatus.SC_BAD_REQUEST) .extract().as(ValidationErrorResponse.class); assertValidationErrorTitle(response); - assertValidationErrorDetails(response); + assertValidationErrorDetail(response); assertValidationErrorStatus(response, HttpStatus.SC_BAD_REQUEST); assertValidationErrorField(response, "validateRequestBody.param.firstCode", "First code must have 3 characters"); assertValidationErrorField(response, "validateRequestBody.param.secondCode", "Second second must match pattern"); @@ -71,7 +71,7 @@ public void shouldGetValidationErrorWhenSingleParamIsLowercase() { .extract().as(ValidationErrorResponse.class); assertValidationErrorTitle(response); - assertValidationErrorDetails(response); + assertValidationErrorDetail(response); assertValidationErrorStatus(response, HttpStatus.SC_BAD_REQUEST); assertValidationErrorField(response, "validateRequestBody.param.custom", "Value must be uppercase"); } diff --git a/304-quarkus-vertx-routes/src/test/java/io/quarkus/qe/validation/ValidationOnRequestParamRouteHandlerTest.java b/304-quarkus-vertx-routes/src/test/java/io/quarkus/qe/validation/ValidationOnRequestParamRouteHandlerTest.java index c9d73d40..567f843d 100644 --- a/304-quarkus-vertx-routes/src/test/java/io/quarkus/qe/validation/ValidationOnRequestParamRouteHandlerTest.java +++ b/304-quarkus-vertx-routes/src/test/java/io/quarkus/qe/validation/ValidationOnRequestParamRouteHandlerTest.java @@ -1,6 +1,6 @@ package io.quarkus.qe.validation; -import static io.quarkus.qe.validation.utils.ValidationAssertions.assertValidationErrorDetails; +import static io.quarkus.qe.validation.utils.ValidationAssertions.assertValidationErrorDetail; import static io.quarkus.qe.validation.utils.ValidationAssertions.assertValidationErrorField; import static io.quarkus.qe.validation.utils.ValidationAssertions.assertValidationErrorStatus; import static io.quarkus.qe.validation.utils.ValidationAssertions.assertValidationErrorTitle; @@ -25,7 +25,7 @@ public void shouldGetValidationErrorWhenSingleParamIsWrong() { .extract().as(ValidationErrorResponse.class); assertValidationErrorTitle(response); - assertValidationErrorDetails(response); + assertValidationErrorDetail(response); assertValidationErrorStatus(response, HttpStatus.SC_BAD_REQUEST); assertValidationErrorField(response, "validateRequestSingleParam.param", "Param must have 3 characters"); } @@ -46,7 +46,7 @@ public void shouldGetValidationErrorsWhenAllParamsAreWrong() { .statusCode(HttpStatus.SC_BAD_REQUEST) .extract().as(ValidationErrorResponse.class); assertValidationErrorTitle(response); - assertValidationErrorDetails(response); + assertValidationErrorDetail(response); assertValidationErrorStatus(response, HttpStatus.SC_BAD_REQUEST); assertValidationErrorField(response, "validateRequestMultipleParam.firstParam", "First param must have 3 characters"); assertValidationErrorField(response, "validateRequestMultipleParam.secondParam", "Second param must match pattern"); @@ -70,7 +70,7 @@ public void shouldGetValidationErrorWhenSingleParamIsLowercase() { .extract().as(ValidationErrorResponse.class); assertValidationErrorTitle(response); - assertValidationErrorDetails(response); + assertValidationErrorDetail(response); assertValidationErrorStatus(response, HttpStatus.SC_BAD_REQUEST); assertValidationErrorField(response, "validateRequestSingleParamUsingCustomValidation.param", "Value must be uppercase"); diff --git a/304-quarkus-vertx-routes/src/test/java/io/quarkus/qe/validation/ValidationOnResponseRouteHandlerTest.java b/304-quarkus-vertx-routes/src/test/java/io/quarkus/qe/validation/ValidationOnResponseRouteHandlerTest.java index 42256382..a389b12a 100644 --- a/304-quarkus-vertx-routes/src/test/java/io/quarkus/qe/validation/ValidationOnResponseRouteHandlerTest.java +++ b/304-quarkus-vertx-routes/src/test/java/io/quarkus/qe/validation/ValidationOnResponseRouteHandlerTest.java @@ -1,6 +1,6 @@ package io.quarkus.qe.validation; -import static io.quarkus.qe.validation.utils.ValidationAssertions.assertValidationErrorDetails; +import static io.quarkus.qe.validation.utils.ValidationAssertions.assertValidationErrorDetail; import static io.quarkus.qe.validation.utils.ValidationAssertions.assertValidationErrorField; import static io.quarkus.qe.validation.utils.ValidationAssertions.assertValidationErrorStatus; import static io.quarkus.qe.validation.utils.ValidationAssertions.assertValidationErrorTitle; @@ -34,7 +34,7 @@ public void shouldGetValidationErrorWhenUniResponseIdIsWrong() { .extract().as(ValidationErrorResponse.class); assertValidationErrorTitle(response); - assertValidationErrorDetails(response); + assertValidationErrorDetail(response); assertValidationErrorStatus(response, HttpStatus.SC_INTERNAL_SERVER_ERROR); assertValidationErrorField(response, "id", "id can't be null"); } @@ -50,7 +50,7 @@ public void shouldGetValidationErrorWhenUniResponseStringIsWrong() { .extract().as(ValidationErrorResponse.class); assertValidationErrorTitle(response); - assertValidationErrorDetails(response); + assertValidationErrorDetail(response); assertValidationErrorStatus(response, HttpStatus.SC_INTERNAL_SERVER_ERROR); } } diff --git a/304-quarkus-vertx-routes/src/test/java/io/quarkus/qe/validation/utils/ValidationAssertions.java b/304-quarkus-vertx-routes/src/test/java/io/quarkus/qe/validation/utils/ValidationAssertions.java index 1bef9e68..c9c3775e 100644 --- a/304-quarkus-vertx-routes/src/test/java/io/quarkus/qe/validation/utils/ValidationAssertions.java +++ b/304-quarkus-vertx-routes/src/test/java/io/quarkus/qe/validation/utils/ValidationAssertions.java @@ -16,8 +16,8 @@ public static final void assertValidationErrorTitle(ValidationErrorResponse resp assertEquals("Constraint Violation", response.getTitle()); } - public static final void assertValidationErrorDetails(ValidationErrorResponse response) { - assertEquals("validation constraint violations", response.getDetails()); + public static final void assertValidationErrorDetail(ValidationErrorResponse response) { + assertEquals("validation constraint violations", response.getDetail()); } public static final void assertValidationErrorStatus(ValidationErrorResponse response, int expected) { diff --git a/304-quarkus-vertx-routes/src/test/java/io/quarkus/qe/validation/utils/ValidationErrorResponse.java b/304-quarkus-vertx-routes/src/test/java/io/quarkus/qe/validation/utils/ValidationErrorResponse.java index 2d7ef42d..93af9e93 100644 --- a/304-quarkus-vertx-routes/src/test/java/io/quarkus/qe/validation/utils/ValidationErrorResponse.java +++ b/304-quarkus-vertx-routes/src/test/java/io/quarkus/qe/validation/utils/ValidationErrorResponse.java @@ -2,7 +2,7 @@ public class ValidationErrorResponse { private String title; - private String details; + private String detail; private int status; private ValidationError[] violations; @@ -14,12 +14,12 @@ public void setTitle(String title) { this.title = title; } - public String getDetails() { - return details; + public String getDetail() { + return detail; } - public void setDetails(String details) { - this.details = details; + public void setDetail(String detail) { + this.detail = detail; } public int getStatus() { diff --git a/pom.xml b/pom.xml index ad31462d..b58e196a 100644 --- a/pom.xml +++ b/pom.xml @@ -32,9 +32,8 @@ 300-quarkus-vertx-webClient 301-quarkus-vertx-kafka 302-quarkus-vertx-jwt - - + 303-quarkus-vertx-sql + 304-quarkus-vertx-routes 601-spring-data-primitive-types 602-spring-data-rest 603-spring-web-smallrye-openapi