File tree Expand file tree Collapse file tree 2 files changed +13
-4
lines changed
buildSrc/src/test/java/org/springframework/boot/build
spring-boot-project/spring-boot-docs/src/docs/antora/modules/tutorial/pages/first-application Expand file tree Collapse file tree 2 files changed +13
-4
lines changed Original file line number Diff line number Diff line change @@ -76,7 +76,9 @@ void jarIncludesLegalFiles() throws IOException {
7676 out .println (" id 'org.springframework.boot.conventions'" );
7777 out .println ("}" );
7878 out .println ("version = '1.2.3'" );
79- out .println ("sourceCompatibility = '17'" );
79+ out .println ("java {" );
80+ out .println (" sourceCompatibility = '17'" );
81+ out .println ("}" );
8082 out .println ("description 'Test project for manifest customization'" );
8183 out .println ("jar.archiveFileName = 'test.jar'" );
8284 }
@@ -106,7 +108,9 @@ void sourceJarIsBuilt() throws IOException {
106108 out .println (" id 'org.springframework.boot.conventions'" );
107109 out .println ("}" );
108110 out .println ("version = '1.2.3'" );
109- out .println ("sourceCompatibility = '17'" );
111+ out .println ("java {" );
112+ out .println (" sourceCompatibility = '17'" );
113+ out .println ("}" );
110114 out .println ("description 'Test'" );
111115 }
112116 runGradle ("assemble" );
@@ -135,7 +139,9 @@ void javadocJarIsBuilt() throws IOException {
135139 out .println (" id 'org.springframework.boot.conventions'" );
136140 out .println ("}" );
137141 out .println ("version = '1.2.3'" );
138- out .println ("sourceCompatibility = '17'" );
142+ out .println ("java {" );
143+ out .println (" sourceCompatibility = '17'" );
144+ out .println ("}" );
139145 out .println ("description 'Test'" );
140146 }
141147 runGradle ("assemble" );
Original file line number Diff line number Diff line change @@ -180,7 +180,10 @@ apply plugin: 'io.spring.dependency-management'
180180
181181group = 'com.example'
182182version = '0.0.1-SNAPSHOT'
183- sourceCompatibility = '17'
183+
184+ java {
185+ sourceCompatibility = '17'
186+ }
184187
185188repositories {
186189 mavenCentral()
You can’t perform that action at this time.
0 commit comments