Skip to content

Commit 4a688f7

Browse files
committed
Use functional api for lombok ITs
1 parent 321c589 commit 4a688f7

File tree

1 file changed

+4
-4
lines changed
  • java-compiler-testing/src/it/lombok/src/test/java/io/github/ascopes/jct/acceptancetests/lombok

1 file changed

+4
-4
lines changed

java-compiler-testing/src/it/lombok/src/test/java/io/github/ascopes/jct/acceptancetests/lombok/LombokTest.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ class LombokTest {
3737
@DisplayName("Lombok @Data compiles the expected data class")
3838
@JavacCompilerTest
3939
void lombokDataCompilesTheExpectedDataClass(JctCompiler compiler) throws Throwable {
40-
try (var workspace = Workspaces.newWorkspace()) {
40+
Workspaces.newWorkspace().use(workspace -> {
4141
// Given
4242
workspace
4343
.createSourcePathPackage()
@@ -63,13 +63,13 @@ void lombokDataCompilesTheExpectedDataClass(JctCompiler compiler) throws Throwab
6363
softly.assertThat(animal).hasFieldOrPropertyWithValue("legCount", 4);
6464
softly.assertThat(animal).hasFieldOrPropertyWithValue("age", 5);
6565
});
66-
}
66+
});
6767
}
6868

6969
@DisplayName("Lombok @Data compiles the expected data class with module support")
7070
@JavacCompilerTest(minVersion = 9)
7171
void lombokDataCompilesTheExpectedDataClassJpms(JctCompiler compiler) throws Throwable {
72-
try (var workspace = Workspaces.newWorkspace()) {
72+
Workspaces.newWorkspace().use(workspace -> {
7373
// Given
7474
workspace
7575
.createSourcePathPackage()
@@ -95,6 +95,6 @@ void lombokDataCompilesTheExpectedDataClassJpms(JctCompiler compiler) throws Thr
9595
softly.assertThat(animal).hasFieldOrPropertyWithValue("legCount", 4);
9696
softly.assertThat(animal).hasFieldOrPropertyWithValue("age", 5);
9797
});
98-
}
98+
});
9999
}
100100
}

0 commit comments

Comments
 (0)