|
29 | 29 | import java.util.List;
|
30 | 30 | import org.apache.commons.io.FileUtils;
|
31 | 31 | import org.junit.jupiter.api.BeforeAll;
|
32 |
| -import org.junit.jupiter.api.Disabled; |
33 | 32 | import org.junit.jupiter.api.Test;
|
34 | 33 | import org.junit.jupiter.api.condition.EnabledIf;
|
35 |
| -import software.amazon.awssdk.testutils.SdkVersionUtils; |
36 | 34 | import software.amazon.awssdk.utils.Logger;
|
37 | 35 |
|
38 | 36 | public class MavenProjectTest {
|
@@ -69,16 +67,17 @@ private static void deleteTempDirectories() throws IOException {
|
69 | 67 | }
|
70 | 68 |
|
71 | 69 | @Test
|
72 |
| - // @EnabledIf("versionAvailable") |
73 |
| - @Disabled("Test is flaky") |
| 70 | + @EnabledIf("versionAvailable") |
74 | 71 | void mavenProject_shouldConvert() throws IOException {
|
75 | 72 | verifyTransformation();
|
76 | 73 | verifyCompilation();
|
77 | 74 | }
|
78 | 75 |
|
79 | 76 | private static void verifyTransformation() throws IOException {
|
80 | 77 | List<String> rewriteArgs = new ArrayList<>();
|
81 |
| - addAll(rewriteArgs, "mvn", "org.openrewrite.maven:rewrite-maven-plugin:run", |
| 78 | + // pin version since updates have broken tests |
| 79 | + String rewriteMavenPluginVersion = "5.43.0"; |
| 80 | + addAll(rewriteArgs, "mvn", "org.openrewrite.maven:rewrite-maven-plugin:" + rewriteMavenPluginVersion + ":run", |
82 | 81 | "-Drewrite.recipeArtifactCoordinates=software.amazon.awssdk:v2-migration:"+ getMigrationToolVersion() + "-PREVIEW",
|
83 | 82 | "-Drewrite.activeRecipes=software.amazon.awssdk.v2migration.AwsSdkJavaV1ToV2");
|
84 | 83 |
|
|
0 commit comments