From 22ce1c27a451de44b0cd52d8a888ed1a11ef6870 Mon Sep 17 00:00:00 2001 From: Denislav Prinov Date: Tue, 17 Oct 2023 13:37:08 +0300 Subject: [PATCH] Rest API doc generation test - fix (#1453) * Added SharedSqlTestDatabaseExtension in Rest API doc test - generation Signed-off-by: Denislav Prinov * Remove Active profile import Signed-off-by: Denislav Prinov --------- Signed-off-by: Denislav Prinov --- .../test/java/org/eclipse/hawkbit/app/RestApiDocTest.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/hawkbit-runtime/hawkbit-update-server/src/test/java/org/eclipse/hawkbit/app/RestApiDocTest.java b/hawkbit-runtime/hawkbit-update-server/src/test/java/org/eclipse/hawkbit/app/RestApiDocTest.java index 79f1c6ffa..990a64593 100644 --- a/hawkbit-runtime/hawkbit-update-server/src/test/java/org/eclipse/hawkbit/app/RestApiDocTest.java +++ b/hawkbit-runtime/hawkbit-update-server/src/test/java/org/eclipse/hawkbit/app/RestApiDocTest.java @@ -12,13 +12,14 @@ package org.eclipse.hawkbit.app; import com.fasterxml.jackson.databind.node.ArrayNode; import com.fasterxml.jackson.dataformat.yaml.YAMLMapper; +import org.eclipse.hawkbit.repository.test.util.SharedSqlTestDatabaseExtension; import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.extension.ExtendWith; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.boot.test.context.SpringBootTest; import org.springframework.boot.test.web.client.TestRestTemplate; import org.springframework.boot.test.web.server.LocalServerPort; import org.springframework.http.ResponseEntity; -import org.springframework.test.context.ActiveProfiles; import com.fasterxml.jackson.databind.JsonNode; import com.fasterxml.jackson.databind.ObjectMapper; import com.fasterxml.jackson.databind.node.ObjectNode; @@ -33,7 +34,7 @@ import java.util.List; import static org.assertj.core.api.Assertions.assertThat; @SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT) -@ActiveProfiles({"maven"}) +@ExtendWith({SharedSqlTestDatabaseExtension.class}) class RestApiDocTest { private static final String MANAGEMENT_PREFIX = "mgmt-openapi"; private static final String DDI_PREFIX = "ddi-openapi";