File tree Expand file tree Collapse file tree 4 files changed +11
-5
lines changed
consumer_java/src/test/java/com/example Expand file tree Collapse file tree 4 files changed +11
-5
lines changed Original file line number Diff line number Diff line change 33import com .fasterxml .jackson .databind .ObjectMapper ;
44
55import org .junit .jupiter .api .BeforeEach ;
6+
7+ import org .springframework .boot .autoconfigure .ImportAutoConfiguration ;
68import org .springframework .boot .test .json .JacksonTester ;
9+ import org .springframework .cloud .stream .binder .test .TestChannelBinderConfiguration ;
710
811/**
912 * @author Marcin Grzejszczak
1013 */
14+ @ ImportAutoConfiguration (TestChannelBinderConfiguration .class )
1115public abstract class AbstractTest {
1216
1317 public JacksonTester <Person > json ;
Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ plugins {
1212
1313group = " com.example"
1414version = " 0.0.1-SNAPSHOT"
15- java.sourceCompatibility = JavaVersion .VERSION_11
15+ java.sourceCompatibility = JavaVersion .VERSION_17
1616
1717
1818repositories {
@@ -79,7 +79,7 @@ tasks {
7979tasks.withType<KotlinCompile >().configureEach {
8080 kotlinOptions {
8181 freeCompilerArgs = listOf (" -Xjsr305=strict" )
82- jvmTarget = " 11 "
82+ jvmTarget = " 17 "
8383 }
8484}
8585
Original file line number Diff line number Diff line change @@ -14,7 +14,7 @@ plugins {
1414
1515group = " com.example"
1616version = " 0.0.1-SNAPSHOT"
17- java.sourceCompatibility = JavaVersion .VERSION_11
17+ java.sourceCompatibility = JavaVersion .VERSION_17
1818
1919
2020repositories {
@@ -36,7 +36,7 @@ dependencyManagement {
3636 }
3737}
3838
39-
39+ extra[ " rest-assured.version " ] = " 5.2.1 "
4040
4141dependencies {
4242 implementation(" org.springframework.boot:spring-boot-starter-web" )
@@ -60,6 +60,7 @@ dependencies {
6060
6161
6262contracts {
63+ contractsDslDir.set(file(" src/test/resources/contracts" ))
6364 testFramework.set(org.springframework.cloud.contract.verifier.config.TestFramework .JUNIT5 )
6465 packageWithBaseClasses.set(" com.example.fraud" )
6566}
@@ -95,7 +96,7 @@ tasks {
9596tasks.withType<KotlinCompile >().configureEach {
9697 kotlinOptions {
9798 freeCompilerArgs = listOf (" -Xjsr305=strict" )
98- jvmTarget = " 11 "
99+ jvmTarget = " 17 "
99100 }
100101}
101102
Original file line number Diff line number Diff line change 2525 <spring-cloud .version>2022.0.0-SNAPSHOT</spring-cloud .version>
2626 <!-- Needs to align the version to what's there in Contract -->
2727 <kotlin .version>1.6.21</kotlin .version>
28+ <rest-assured .version>5.2.1</rest-assured .version>
2829 </properties >
2930
3031 <dependencies >
You can’t perform that action at this time.
0 commit comments