From 50945ac434cd3b9b04e60ea608f5ead4209f9f07 Mon Sep 17 00:00:00 2001 From: Oliver Gierke Date: Thu, 21 Sep 2017 16:45:55 +0200 Subject: [PATCH] #297 - Upgraded to Thymeleaf Spring Data dialect compatible with Thymeleaf 3. --- web/querydsl/pom.xml | 2 +- .../main/java/example/users/Application.java | 4 +-- .../java/example/users/ApplicationTests.java | 32 +++++++++++++++++++ 3 files changed, 35 insertions(+), 3 deletions(-) create mode 100644 web/querydsl/src/test/java/example/users/ApplicationTests.java diff --git a/web/querydsl/pom.xml b/web/querydsl/pom.xml index 2380381a..2876bc72 100644 --- a/web/querydsl/pom.xml +++ b/web/querydsl/pom.xml @@ -57,7 +57,7 @@ io.github.jpenren thymeleaf-spring-data-dialect - 2.1.1 + 3.3.0 diff --git a/web/querydsl/src/main/java/example/users/Application.java b/web/querydsl/src/main/java/example/users/Application.java index f85da8e0..0c5ba164 100644 --- a/web/querydsl/src/main/java/example/users/Application.java +++ b/web/querydsl/src/main/java/example/users/Application.java @@ -21,7 +21,7 @@ import org.springframework.beans.factory.annotation.Autowired; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; import org.springframework.context.annotation.Bean; -import org.springframework.web.servlet.config.annotation.WebMvcConfigurerAdapter; +import org.springframework.web.servlet.config.annotation.WebMvcConfigurer; import org.thymeleaf.dialect.springdata.SpringDataDialect; /** @@ -29,7 +29,7 @@ import org.thymeleaf.dialect.springdata.SpringDataDialect; * @author Oliver Gierke */ @SpringBootApplication -public class Application extends WebMvcConfigurerAdapter { +public class Application implements WebMvcConfigurer { public static void main(String[] args) { SpringApplication.run(Application.class, args); diff --git a/web/querydsl/src/test/java/example/users/ApplicationTests.java b/web/querydsl/src/test/java/example/users/ApplicationTests.java new file mode 100644 index 00000000..1ab514f2 --- /dev/null +++ b/web/querydsl/src/test/java/example/users/ApplicationTests.java @@ -0,0 +1,32 @@ +/* + * Copyright 2017 the original author or authors. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package example.users; + +import org.junit.Test; +import org.junit.runner.RunWith; +import org.springframework.boot.autoconfigure.SpringBootApplication; +import org.springframework.test.context.junit4.SpringRunner; + +/** + * @author Oliver Gierke + */ +@RunWith(SpringRunner.class) +@SpringBootApplication +public class ApplicationTests { + + @Test + public void contextBootstraps() {} +}