From 1537cfa74c4bd11c7a517664f5db407fdaf7827e Mon Sep 17 00:00:00 2001 From: John Kelly Date: Mon, 15 Aug 2016 20:47:15 -0400 Subject: [PATCH] Upgrade to Spring Boot 1.4 --- build.gradle | 2 +- gradle.properties | 6 +++--- gradle/wrapper/gradle-wrapper.properties | 4 ++-- .../build.gradle | 2 +- graphiql-spring-boot-starter/build.gradle | 2 +- graphql-sample-app/build.gradle | 4 ++-- .../test/GenericTodoSchemaParserTest.java | 21 ++++++++----------- .../build.gradle | 2 +- graphql-spring-boot-starter/build.gradle | 2 +- 9 files changed, 21 insertions(+), 24 deletions(-) diff --git a/build.gradle b/build.gradle index edeeaced..967379c3 100644 --- a/build.gradle +++ b/build.gradle @@ -26,7 +26,7 @@ buildscript { } dependencies { classpath 'org.springframework.build.gradle:propdeps-plugin:0.0.7' - classpath "com.jfrog.bintray.gradle:gradle-bintray-plugin:1.6" + classpath "com.jfrog.bintray.gradle:gradle-bintray-plugin:1.7.1" } } diff --git a/gradle.properties b/gradle.properties index f5b5db93..4521e232 100644 --- a/gradle.properties +++ b/gradle.properties @@ -38,9 +38,9 @@ TARGET_COMPATIBILITY = 1.8 LIB_SPRING_GRAPHQL_COMMON_VER = 2.1.+ LIB_JUNIT_VER = 4.12 -LIB_SPRING_CORE_VER = 4.2.4.RELEASE -LIB_SPRING_BOOT_VER = 1.3.3.RELEASE -LIB_COMMON_UPLOAD = 1.3.1 +LIB_SPRING_CORE_VER = 4.3.2.RELEASE +LIB_SPRING_BOOT_VER = 1.4.0.RELEASE +LIB_COMMON_UPLOAD = 1.3.2 GRADLE_WRAPPER_VER = 2.9 diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 408b61a2..1d86c9ed 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ -#Sun Mar 27 20:34:11 BST 2016 +#Mon Aug 15 20:29:03 EDT 2016 distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-2.9-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-2.9-all.zip diff --git a/graphiql-spring-boot-autoconfigure/build.gradle b/graphiql-spring-boot-autoconfigure/build.gradle index fcb5d7c1..676ce6e6 100644 --- a/graphiql-spring-boot-autoconfigure/build.gradle +++ b/graphiql-spring-boot-autoconfigure/build.gradle @@ -21,7 +21,7 @@ buildscript { maven { url "https://plugins.gradle.org/m2/" } } dependencies { - classpath "com.jfrog.bintray.gradle:gradle-bintray-plugin:1.6" + classpath "com.jfrog.bintray.gradle:gradle-bintray-plugin:1.7.1" } } diff --git a/graphiql-spring-boot-starter/build.gradle b/graphiql-spring-boot-starter/build.gradle index 13e11137..be7f09ed 100644 --- a/graphiql-spring-boot-starter/build.gradle +++ b/graphiql-spring-boot-starter/build.gradle @@ -21,7 +21,7 @@ buildscript { maven { url "https://plugins.gradle.org/m2/" } } dependencies { - classpath "com.jfrog.bintray.gradle:gradle-bintray-plugin:1.6" + classpath "com.jfrog.bintray.gradle:gradle-bintray-plugin:1.7.1" } } diff --git a/graphql-sample-app/build.gradle b/graphql-sample-app/build.gradle index 536d13fd..15385e17 100644 --- a/graphql-sample-app/build.gradle +++ b/graphql-sample-app/build.gradle @@ -22,8 +22,8 @@ buildscript { maven { url 'http://repo.spring.io/plugins-release' } } dependencies { - classpath("org.springframework.boot:spring-boot-gradle-plugin:1.3.3.RELEASE") - classpath "com.jfrog.bintray.gradle:gradle-bintray-plugin:1.6" + classpath("org.springframework.boot:spring-boot-gradle-plugin:1.4.0.RELEASE") + classpath "com.jfrog.bintray.gradle:gradle-bintray-plugin:1.7.1" } } diff --git a/graphql-sample-app/src/test/java/com/embedler/moon/graphql/boot/sample/test/GenericTodoSchemaParserTest.java b/graphql-sample-app/src/test/java/com/embedler/moon/graphql/boot/sample/test/GenericTodoSchemaParserTest.java index 51da6cdf..a018521a 100644 --- a/graphql-sample-app/src/test/java/com/embedler/moon/graphql/boot/sample/test/GenericTodoSchemaParserTest.java +++ b/graphql-sample-app/src/test/java/com/embedler/moon/graphql/boot/sample/test/GenericTodoSchemaParserTest.java @@ -19,7 +19,6 @@ package com.embedler.moon.graphql.boot.sample.test; -import com.embedler.moon.graphql.boot.sample.ApplicationBootConfiguration; import com.fasterxml.jackson.databind.ObjectMapper; import com.oembedler.moon.graphql.boot.GraphQLServerRequest; import com.oembedler.moon.graphql.boot.GraphQLServerResult; @@ -28,18 +27,15 @@ import org.junit.runner.RunWith; import org.slf4j.Logger; import org.slf4j.LoggerFactory; +import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Value; -import org.springframework.boot.test.IntegrationTest; -import org.springframework.boot.test.SpringApplicationConfiguration; -import org.springframework.boot.test.TestRestTemplate; -import org.springframework.boot.test.WebIntegrationTest; +import org.springframework.boot.test.context.SpringBootTest; +import org.springframework.boot.test.web.client.TestRestTemplate; import org.springframework.core.io.ClassPathResource; import org.springframework.http.*; -import org.springframework.test.context.junit4.SpringJUnit4ClassRunner; -import org.springframework.test.context.web.WebAppConfiguration; +import org.springframework.test.context.junit4.SpringRunner; import org.springframework.util.CollectionUtils; import org.springframework.util.LinkedMultiValueMap; -import org.springframework.web.client.RestTemplate; import java.io.IOException; import java.util.HashMap; @@ -48,9 +44,8 @@ /** * @author oEmbedler Inc. */ -@RunWith(SpringJUnit4ClassRunner.class) -@SpringApplicationConfiguration(ApplicationBootConfiguration.class) -@WebIntegrationTest("server.port=0") +@RunWith(SpringRunner.class) +@SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT) public class GenericTodoSchemaParserTest { private static final Logger LOGGER = LoggerFactory.getLogger(GenericTodoSchemaParserTest.class); @@ -58,7 +53,9 @@ public class GenericTodoSchemaParserTest { @Value("${local.server.port}") private int port; - private RestTemplate restTemplate = new TestRestTemplate(); + @Autowired + private TestRestTemplate restTemplate; + private ObjectMapper objectMapper = new ObjectMapper(); @Test diff --git a/graphql-spring-boot-autoconfigure/build.gradle b/graphql-spring-boot-autoconfigure/build.gradle index d49f23c8..7d084b3f 100644 --- a/graphql-spring-boot-autoconfigure/build.gradle +++ b/graphql-spring-boot-autoconfigure/build.gradle @@ -22,7 +22,7 @@ buildscript { maven { url "https://plugins.gradle.org/m2/" } } dependencies { - classpath "com.jfrog.bintray.gradle:gradle-bintray-plugin:1.6" + classpath "com.jfrog.bintray.gradle:gradle-bintray-plugin:1.7.1" } } diff --git a/graphql-spring-boot-starter/build.gradle b/graphql-spring-boot-starter/build.gradle index 212ef10c..66625a5a 100644 --- a/graphql-spring-boot-starter/build.gradle +++ b/graphql-spring-boot-starter/build.gradle @@ -21,7 +21,7 @@ buildscript { maven { url "https://plugins.gradle.org/m2/" } } dependencies { - classpath "com.jfrog.bintray.gradle:gradle-bintray-plugin:1.6" + classpath "com.jfrog.bintray.gradle:gradle-bintray-plugin:1.7.1" } }