diff options
author | Singal, Kapil (ks220y) <ks220y@att.com> | 2020-09-22 12:16:46 -0400 |
---|---|---|
committer | Singal, Kapil (ks220y) <ks220y@att.com> | 2020-09-22 13:49:05 -0400 |
commit | 1072867dfac0df993cbd3e44bcc11a5cac7465fd (patch) | |
tree | 4a821659cf3b50cf946cbb535d528be8508e9fff /ms/blueprintsprocessor/modules/inbounds/resource-api/src/test | |
parent | d97021cd756d63402545fdc2e14ac7611c3da118 (diff) |
Enabling Code Formatter
Code Formatter was turned off due to java 11 migation
Issue-ID: CCSDK-2852
Signed-off-by: Singal, Kapil (ks220y) <ks220y@att.com>
Change-Id: I3d02ed3cc7a93d7551fe25356512cfe8db1517d8
Diffstat (limited to 'ms/blueprintsprocessor/modules/inbounds/resource-api/src/test')
4 files changed, 22 insertions, 13 deletions
diff --git a/ms/blueprintsprocessor/modules/inbounds/resource-api/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/resource/api/ErrorCatalogTestConfiguration.kt b/ms/blueprintsprocessor/modules/inbounds/resource-api/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/resource/api/ErrorCatalogTestConfiguration.kt index 5b0d1980b..8a52884ac 100644 --- a/ms/blueprintsprocessor/modules/inbounds/resource-api/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/resource/api/ErrorCatalogTestConfiguration.kt +++ b/ms/blueprintsprocessor/modules/inbounds/resource-api/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/resource/api/ErrorCatalogTestConfiguration.kt @@ -22,7 +22,7 @@ import org.springframework.context.annotation.Configuration @Configuration @ComponentScan( - basePackages = ["org.onap.ccsdk.cds.error.catalog"] + basePackages = ["org.onap.ccsdk.cds.error.catalog"] ) @EnableAutoConfiguration open class ErrorCatalogTestConfiguration diff --git a/ms/blueprintsprocessor/modules/inbounds/resource-api/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/resource/api/ResourceControllerTest.kt b/ms/blueprintsprocessor/modules/inbounds/resource-api/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/resource/api/ResourceControllerTest.kt index c5e002f08..40d6f56cb 100644 --- a/ms/blueprintsprocessor/modules/inbounds/resource-api/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/resource/api/ResourceControllerTest.kt +++ b/ms/blueprintsprocessor/modules/inbounds/resource-api/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/resource/api/ResourceControllerTest.kt @@ -40,13 +40,17 @@ import org.springframework.test.web.reactive.server.WebTestClient @RunWith(SpringRunner::class) @WebFluxTest @ContextConfiguration( - classes = [TestDatabaseConfiguration::class, ErrorCatalogTestConfiguration::class, - ResourceController::class, ResourceResolutionDBService::class] + classes = [ + TestDatabaseConfiguration::class, ErrorCatalogTestConfiguration::class, + ResourceController::class, ResourceResolutionDBService::class + ] ) @ComponentScan( - basePackages = ["org.onap.ccsdk.cds.controllerblueprints.core.service", + basePackages = [ + "org.onap.ccsdk.cds.controllerblueprints.core.service", "org.onap.ccsdk.cds.blueprintsprocessor.resource.api", - "org.onap.ccsdk.cds.blueprintsprocessor.functions.resource.resolution"] + "org.onap.ccsdk.cds.blueprintsprocessor.functions.resource.resolution" + ] ) @TestPropertySource(locations = ["classpath:application-test.properties"]) class ResourceControllerTest { @@ -55,6 +59,7 @@ class ResourceControllerTest { @Autowired lateinit var resourceResolutionDBService: ResourceResolutionDBService + @Autowired lateinit var webTestClient: WebTestClient @@ -150,9 +155,9 @@ class ResourceControllerTest { .consumeWith { val r = JacksonUtils.objectMapper.readValue(it.responseBody, ErrorPayload::class.java) Assert.assertEquals( - "Cause: Missing param. Either retrieve resolved value using artifact name and " + - "resolution-key OR using resource-id and resource-type. \n" + - " Action : Please verify your request.", + "Cause: Missing param. Either retrieve resolved value using artifact name and " + + "resolution-key OR using resource-id and resource-type. \n" + + " Action : Please verify your request.", r.message ) } @@ -172,7 +177,7 @@ class ResourceControllerTest { val r = JacksonUtils.objectMapper.readValue(it.responseBody, ErrorPayload::class.java) Assert.assertEquals( "Cause: Either retrieve resolved value using artifact name and resolution-key OR using " + - "resource-id and resource-type. \n Action : Please verify your request.", + "resource-id and resource-type. \n Action : Please verify your request.", r.message ) } diff --git a/ms/blueprintsprocessor/modules/inbounds/resource-api/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/resource/api/TemplateControllerTest.kt b/ms/blueprintsprocessor/modules/inbounds/resource-api/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/resource/api/TemplateControllerTest.kt index 098423540..945a30c64 100644 --- a/ms/blueprintsprocessor/modules/inbounds/resource-api/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/resource/api/TemplateControllerTest.kt +++ b/ms/blueprintsprocessor/modules/inbounds/resource-api/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/resource/api/TemplateControllerTest.kt @@ -37,8 +37,10 @@ import kotlin.test.AfterTest @RunWith(SpringRunner::class) @WebFluxTest @ContextConfiguration( - classes = [TestDatabaseConfiguration::class, BluePrintCoreConfiguration::class, - BluePrintCatalogService::class, ErrorCatalogTestConfiguration::class] + classes = [ + TestDatabaseConfiguration::class, BluePrintCoreConfiguration::class, + BluePrintCatalogService::class, ErrorCatalogTestConfiguration::class + ] ) @ComponentScan(basePackages = ["org.onap.ccsdk.cds.blueprintsprocessor", "org.onap.ccsdk.cds.controllerblueprints"]) @TestPropertySource(locations = ["classpath:application-test.properties"]) diff --git a/ms/blueprintsprocessor/modules/inbounds/resource-api/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/resource/api/TestDatabaseConfiguration.kt b/ms/blueprintsprocessor/modules/inbounds/resource-api/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/resource/api/TestDatabaseConfiguration.kt index 0ab3b5b21..6d87d2735 100644 --- a/ms/blueprintsprocessor/modules/inbounds/resource-api/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/resource/api/TestDatabaseConfiguration.kt +++ b/ms/blueprintsprocessor/modules/inbounds/resource-api/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/resource/api/TestDatabaseConfiguration.kt @@ -31,8 +31,10 @@ import javax.sql.DataSource @Configuration @Import(BluePrintDBLibConfiguration::class) @EnableJpaRepositories( - basePackages = ["org.onap.ccsdk.cds.blueprintsprocessor.db.primary", - "org.onap.ccsdk.cds.blueprintsprocessor.functions.resource.resolution"], + basePackages = [ + "org.onap.ccsdk.cds.blueprintsprocessor.db.primary", + "org.onap.ccsdk.cds.blueprintsprocessor.functions.resource.resolution" + ], entityManagerFactoryRef = "primaryEntityManager", transactionManagerRef = "primaryTransactionManager" ) |