Skip to content
This repository was archived by the owner on Dec 19, 2023. It is now read-only.

Commit f5333e9

Browse files
committed
Fixed some unit tests and bumped version for release 5.0.5
1 parent a8def22 commit f5333e9

File tree

5 files changed

+31
-15
lines changed

5 files changed

+31
-15
lines changed

README.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -42,13 +42,13 @@ repositories {
4242
}
4343
4444
dependencies {
45-
compile 'com.graphql-java-kickstart:graphql-spring-boot-starter:5.0.4'
45+
compile 'com.graphql-java-kickstart:graphql-spring-boot-starter:5.0.5'
4646
4747
// to embed GraphiQL tool
48-
compile 'com.graphql-java-kickstart:graphiql-spring-boot-starter:5.0.4'
48+
compile 'com.graphql-java-kickstart:graphiql-spring-boot-starter:5.0.5'
4949
5050
// to embed Voyager tool
51-
compile 'com.graphql-java-kickstart:voyager-spring-boot-starter:5.0.4'
51+
compile 'com.graphql-java-kickstart:voyager-spring-boot-starter:5.0.5'
5252
}
5353
```
5454

@@ -57,21 +57,21 @@ Maven:
5757
<dependency>
5858
<groupId>com.graphql-java-kickstart</groupId>
5959
<artifactId>graphql-spring-boot-starter</artifactId>
60-
<version>5.0.4</version>
60+
<version>5.0.5</version>
6161
</dependency>
6262

6363
<!-- to embed GraphiQL tool -->
6464
<dependency>
6565
<groupId>com.graphql-java-kickstart</groupId>
6666
<artifactId>graphiql-spring-boot-starter</artifactId>
67-
<version>5.0.4</version>
67+
<version>5.0.5</version>
6868
</dependency>
6969

7070
<!-- to embed Voyager tool -->
7171
<dependency>
7272
<groupId>com.graphql-java-kickstart</groupId>
7373
<artifactId>voyager-spring-boot-starter</artifactId>
74-
<version>5.0.4</version>
74+
<version>5.0.5</version>
7575
</dependency>
7676
```
7777

Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
package com.oembedler.moon.graphql.boot;
2+
3+
import org.junit.Test;
4+
import org.junit.runner.RunWith;
5+
import org.springframework.boot.test.context.SpringBootTest;
6+
import org.springframework.test.context.junit4.SpringRunner;
7+
8+
@RunWith(SpringRunner.class)
9+
@SpringBootTest
10+
public class SpringBootTestWithoutWebEnvironmentTest {
11+
12+
@Test
13+
public void loads_without_complaining_about_missing_ServerContainer() {
14+
15+
}
16+
17+
}

gradle.properties

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
1818
#
1919

20-
version = 5.0.5-SNAPSHOT
20+
version = 5.0.5
2121
PROJECT_GROUP = com.graphql-java-kickstart
2222
PROJECT_NAME = graphql-spring-boot
2323
PROJECT_DESC = GraphQL Spring Framework Boot
@@ -40,8 +40,8 @@ LIB_GRAPHQL_JAVA_VER = 9.2
4040
LIB_JUNIT_VER = 4.12
4141
LIB_SPRING_CORE_VER = 5.0.4.RELEASE
4242
LIB_SPRING_BOOT_VER = 2.0.5.RELEASE
43-
LIB_GRAPHQL_SERVLET_VER = 6.1.4
44-
LIB_GRAPHQL_JAVA_TOOLS_VER = 5.3.4-SNAPSHOT
43+
LIB_GRAPHQL_SERVLET_VER = 6.2.0
44+
LIB_GRAPHQL_JAVA_TOOLS_VER = 5.3.4
4545
LIB_COMMONS_IO_VER = 2.6
4646

4747
GRADLE_WRAPPER_VER = 4.7

graphql-spring-boot-autoconfigure/src/main/java/com/oembedler/moon/graphql/boot/GraphQLWebsocketAutoConfiguration.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ public ServerEndpointRegistration serverEndpointRegistration(GraphQLWebsocketSer
4141

4242
@Bean
4343
@ConditionalOnMissingBean
44-
@ConditionalOnClass(ServerContainer.class)
44+
@ConditionalOnBean(ServerContainer.class)
4545
public ServerEndpointExporter serverEndpointExporter() {
4646
return new ServerEndpointExporter();
4747
}

graphql-spring-boot-test-autoconfigure/src/main/java/com/graphql/spring/boot/test/GraphQLTestAutoConfiguration.java

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,15 @@
11
package com.graphql.spring.boot.test;
22

3-
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
4-
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
5-
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
6-
import org.springframework.boot.autoconfigure.condition.ConditionalOnWebApplication;
3+
import org.springframework.boot.autoconfigure.condition.*;
4+
import org.springframework.boot.test.web.client.TestRestTemplate;
75
import org.springframework.context.annotation.Bean;
86
import org.springframework.context.annotation.Configuration;
97
import org.springframework.web.servlet.DispatcherServlet;
108

119
@Configuration
1210
@ConditionalOnWebApplication
13-
@ConditionalOnClass(DispatcherServlet.class)
11+
@ConditionalOnBean(TestRestTemplate.class)
12+
@ConditionalOnClass({DispatcherServlet.class})
1413
@ConditionalOnProperty(value = "graphql.servlet.enabled", havingValue = "true", matchIfMissing = true)
1514
public class GraphQLTestAutoConfiguration {
1615

0 commit comments

Comments
 (0)