From 3e2a601af0fcfd9f99dd764fa8bc5a38b8b9fc94 Mon Sep 17 00:00:00 2001 From: Brian Clozel Date: Tue, 15 Sep 2020 14:00:41 +0200 Subject: [PATCH] Move auto-configuration classes to Spring Boot namespace --- .../graphql/servlet/GraphQLEndpointConfiguration.java | 4 ++-- .../springframework/boot/graphql/servlet}/package-info.java | 2 +- .../src/main/resources/META-INF/spring.factories | 2 +- .../{ => boot}/graphql/servlet/IntegrationTest.java | 2 +- .../boot/graphql/servlet}/IntegrationTestConfig.java | 2 +- .../graphql/reactive/GraphQLEndpointConfiguration.java | 2 +- .../springframework/boot/graphql/reactive}/package-info.java | 2 +- .../src/main/resources/META-INF/spring.factories | 2 +- .../{ => boot}/graphql/reactive/IntegrationTest.java | 4 ++-- .../boot/graphql/reactive}/IntegrationTestConfig.java | 2 +- 10 files changed, 12 insertions(+), 12 deletions(-) rename spring-boot-starter-graphql-web/src/main/java/org/springframework/{ => boot}/graphql/servlet/GraphQLEndpointConfiguration.java (93%) rename {spring-boot-starter-graphql-webflux/src/main/java/org/springframework/graphql/reactive => spring-boot-starter-graphql-web/src/main/java/org/springframework/boot/graphql/servlet}/package-info.java (70%) rename spring-boot-starter-graphql-web/src/test/java/org/springframework/{ => boot}/graphql/servlet/IntegrationTest.java (97%) rename {spring-boot-starter-graphql-webflux/src/test/java/org/springframework/graphql/reactive => spring-boot-starter-graphql-web/src/test/java/org/springframework/boot/graphql/servlet}/IntegrationTestConfig.java (86%) rename spring-boot-starter-graphql-webflux/src/main/java/org/springframework/{ => boot}/graphql/reactive/GraphQLEndpointConfiguration.java (93%) rename {spring-boot-starter-graphql-web/src/main/java/org/springframework/graphql/servlet => spring-boot-starter-graphql-webflux/src/main/java/org/springframework/boot/graphql/reactive}/package-info.java (70%) rename spring-boot-starter-graphql-webflux/src/test/java/org/springframework/{ => boot}/graphql/reactive/IntegrationTest.java (93%) rename {spring-boot-starter-graphql-web/src/test/java/org/springframework/graphql/servlet => spring-boot-starter-graphql-webflux/src/test/java/org/springframework/boot/graphql/reactive}/IntegrationTestConfig.java (86%) diff --git a/spring-boot-starter-graphql-web/src/main/java/org/springframework/graphql/servlet/GraphQLEndpointConfiguration.java b/spring-boot-starter-graphql-web/src/main/java/org/springframework/boot/graphql/servlet/GraphQLEndpointConfiguration.java similarity index 93% rename from spring-boot-starter-graphql-web/src/main/java/org/springframework/graphql/servlet/GraphQLEndpointConfiguration.java rename to spring-boot-starter-graphql-web/src/main/java/org/springframework/boot/graphql/servlet/GraphQLEndpointConfiguration.java index 36ead34e..a0dab9b5 100644 --- a/spring-boot-starter-graphql-web/src/main/java/org/springframework/graphql/servlet/GraphQLEndpointConfiguration.java +++ b/spring-boot-starter-graphql-web/src/main/java/org/springframework/boot/graphql/servlet/GraphQLEndpointConfiguration.java @@ -1,11 +1,11 @@ -package org.springframework.graphql.servlet; +package org.springframework.boot.graphql.servlet; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.boot.autoconfigure.condition.ConditionalOnWebApplication; +import org.springframework.graphql.servlet.components.GraphQLController; import org.springframework.context.ApplicationContext; import org.springframework.context.annotation.ComponentScan; import org.springframework.context.annotation.Configuration; -import org.springframework.graphql.servlet.components.GraphQLController; import javax.annotation.PostConstruct; diff --git a/spring-boot-starter-graphql-webflux/src/main/java/org/springframework/graphql/reactive/package-info.java b/spring-boot-starter-graphql-web/src/main/java/org/springframework/boot/graphql/servlet/package-info.java similarity index 70% rename from spring-boot-starter-graphql-webflux/src/main/java/org/springframework/graphql/reactive/package-info.java rename to spring-boot-starter-graphql-web/src/main/java/org/springframework/boot/graphql/servlet/package-info.java index 93ba6435..7909e686 100644 --- a/spring-boot-starter-graphql-webflux/src/main/java/org/springframework/graphql/reactive/package-info.java +++ b/spring-boot-starter-graphql-web/src/main/java/org/springframework/boot/graphql/servlet/package-info.java @@ -1,6 +1,6 @@ @NonNullApi @NonNullFields -package org.springframework.graphql.reactive; +package org.springframework.boot.graphql.servlet; import org.springframework.lang.NonNullApi; import org.springframework.lang.NonNullFields; diff --git a/spring-boot-starter-graphql-web/src/main/resources/META-INF/spring.factories b/spring-boot-starter-graphql-web/src/main/resources/META-INF/spring.factories index 5671ae1a..94fbd530 100644 --- a/spring-boot-starter-graphql-web/src/main/resources/META-INF/spring.factories +++ b/spring-boot-starter-graphql-web/src/main/resources/META-INF/spring.factories @@ -1,2 +1,2 @@ org.springframework.boot.autoconfigure.EnableAutoConfiguration=\ -org.springframework.graphql.servlet.GraphQLEndpointConfiguration +org.springframework.boot.graphql.servlet.GraphQLEndpointConfiguration diff --git a/spring-boot-starter-graphql-web/src/test/java/org/springframework/graphql/servlet/IntegrationTest.java b/spring-boot-starter-graphql-web/src/test/java/org/springframework/boot/graphql/servlet/IntegrationTest.java similarity index 97% rename from spring-boot-starter-graphql-web/src/test/java/org/springframework/graphql/servlet/IntegrationTest.java rename to spring-boot-starter-graphql-web/src/test/java/org/springframework/boot/graphql/servlet/IntegrationTest.java index aa7c8e90..e1f689e8 100644 --- a/spring-boot-starter-graphql-web/src/test/java/org/springframework/graphql/servlet/IntegrationTest.java +++ b/spring-boot-starter-graphql-web/src/test/java/org/springframework/boot/graphql/servlet/IntegrationTest.java @@ -1,4 +1,4 @@ -package org.springframework.graphql.servlet; +package org.springframework.boot.graphql.servlet; import graphql.ExecutionInput; import graphql.ExecutionResultImpl; diff --git a/spring-boot-starter-graphql-webflux/src/test/java/org/springframework/graphql/reactive/IntegrationTestConfig.java b/spring-boot-starter-graphql-web/src/test/java/org/springframework/boot/graphql/servlet/IntegrationTestConfig.java similarity index 86% rename from spring-boot-starter-graphql-webflux/src/test/java/org/springframework/graphql/reactive/IntegrationTestConfig.java rename to spring-boot-starter-graphql-web/src/test/java/org/springframework/boot/graphql/servlet/IntegrationTestConfig.java index 6398bf94..0d77f0aa 100644 --- a/spring-boot-starter-graphql-webflux/src/test/java/org/springframework/graphql/reactive/IntegrationTestConfig.java +++ b/spring-boot-starter-graphql-web/src/test/java/org/springframework/boot/graphql/servlet/IntegrationTestConfig.java @@ -1,4 +1,4 @@ -package org.springframework.graphql.reactive; +package org.springframework.boot.graphql.servlet; import graphql.GraphQL; import org.mockito.Mockito; diff --git a/spring-boot-starter-graphql-webflux/src/main/java/org/springframework/graphql/reactive/GraphQLEndpointConfiguration.java b/spring-boot-starter-graphql-webflux/src/main/java/org/springframework/boot/graphql/reactive/GraphQLEndpointConfiguration.java similarity index 93% rename from spring-boot-starter-graphql-webflux/src/main/java/org/springframework/graphql/reactive/GraphQLEndpointConfiguration.java rename to spring-boot-starter-graphql-webflux/src/main/java/org/springframework/boot/graphql/reactive/GraphQLEndpointConfiguration.java index 1a410f38..b054834f 100644 --- a/spring-boot-starter-graphql-webflux/src/main/java/org/springframework/graphql/reactive/GraphQLEndpointConfiguration.java +++ b/spring-boot-starter-graphql-webflux/src/main/java/org/springframework/boot/graphql/reactive/GraphQLEndpointConfiguration.java @@ -1,4 +1,4 @@ -package org.springframework.graphql.reactive; +package org.springframework.boot.graphql.reactive; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.boot.autoconfigure.condition.ConditionalOnWebApplication; diff --git a/spring-boot-starter-graphql-web/src/main/java/org/springframework/graphql/servlet/package-info.java b/spring-boot-starter-graphql-webflux/src/main/java/org/springframework/boot/graphql/reactive/package-info.java similarity index 70% rename from spring-boot-starter-graphql-web/src/main/java/org/springframework/graphql/servlet/package-info.java rename to spring-boot-starter-graphql-webflux/src/main/java/org/springframework/boot/graphql/reactive/package-info.java index b58e8344..b112b1d9 100644 --- a/spring-boot-starter-graphql-web/src/main/java/org/springframework/graphql/servlet/package-info.java +++ b/spring-boot-starter-graphql-webflux/src/main/java/org/springframework/boot/graphql/reactive/package-info.java @@ -1,6 +1,6 @@ @NonNullApi @NonNullFields -package org.springframework.graphql.servlet; +package org.springframework.boot.graphql.reactive; import org.springframework.lang.NonNullApi; import org.springframework.lang.NonNullFields; diff --git a/spring-boot-starter-graphql-webflux/src/main/resources/META-INF/spring.factories b/spring-boot-starter-graphql-webflux/src/main/resources/META-INF/spring.factories index 98d6f33e..85517296 100644 --- a/spring-boot-starter-graphql-webflux/src/main/resources/META-INF/spring.factories +++ b/spring-boot-starter-graphql-webflux/src/main/resources/META-INF/spring.factories @@ -1,2 +1,2 @@ org.springframework.boot.autoconfigure.EnableAutoConfiguration=\ -org.springframework.graphql.reactive.GraphQLEndpointConfiguration +org.springframework.boot.graphql.reactive.GraphQLEndpointConfiguration diff --git a/spring-boot-starter-graphql-webflux/src/test/java/org/springframework/graphql/reactive/IntegrationTest.java b/spring-boot-starter-graphql-webflux/src/test/java/org/springframework/boot/graphql/reactive/IntegrationTest.java similarity index 93% rename from spring-boot-starter-graphql-webflux/src/test/java/org/springframework/graphql/reactive/IntegrationTest.java rename to spring-boot-starter-graphql-webflux/src/test/java/org/springframework/boot/graphql/reactive/IntegrationTest.java index f1733ae2..adbb74d7 100644 --- a/spring-boot-starter-graphql-webflux/src/test/java/org/springframework/graphql/reactive/IntegrationTest.java +++ b/spring-boot-starter-graphql-webflux/src/test/java/org/springframework/boot/graphql/reactive/IntegrationTest.java @@ -1,4 +1,4 @@ -package org.springframework.graphql.reactive; +package org.springframework.boot.graphql.reactive; import graphql.ExecutionInput; import graphql.ExecutionResultImpl; @@ -50,7 +50,7 @@ public class IntegrationTest { this.webClient.post().uri("/graphql").body(BodyInserters.fromValue(body)).exchange().expectStatus().isOk() .expectBody(Map.class).isEqualTo(expectedResult); - assertThat(captor.getValue().getQuery()).isEqualTo(query); + Assertions.assertThat(captor.getValue().getQuery()).isEqualTo(query); } } \ No newline at end of file diff --git a/spring-boot-starter-graphql-web/src/test/java/org/springframework/graphql/servlet/IntegrationTestConfig.java b/spring-boot-starter-graphql-webflux/src/test/java/org/springframework/boot/graphql/reactive/IntegrationTestConfig.java similarity index 86% rename from spring-boot-starter-graphql-web/src/test/java/org/springframework/graphql/servlet/IntegrationTestConfig.java rename to spring-boot-starter-graphql-webflux/src/test/java/org/springframework/boot/graphql/reactive/IntegrationTestConfig.java index 5a40dcb2..4387ab1e 100644 --- a/spring-boot-starter-graphql-web/src/test/java/org/springframework/graphql/servlet/IntegrationTestConfig.java +++ b/spring-boot-starter-graphql-webflux/src/test/java/org/springframework/boot/graphql/reactive/IntegrationTestConfig.java @@ -1,4 +1,4 @@ -package org.springframework.graphql.servlet; +package org.springframework.boot.graphql.reactive; import graphql.GraphQL; import org.mockito.Mockito;