-
Notifications
You must be signed in to change notification settings - Fork 94
Gradle 9.2.0 #836
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Gradle 9.2.0 #836
Conversation
Use this link to re-run the recipe: https://app.moderne.io/builder/Sh3Bg6DMd?organizationId=QUxML09wZW4gU291cmNlL09wZW5SZXdyaXRl Co-authored-by: Moderne <team@moderne.io>
One is: The other one is: |
|
Second test failure is also due to type information on the Gradle API missing, |
|
Ah that might be the Gradle 9 use of Groovy 4 not quite working well for us then I suppose; let me see if we can work around the issue. |
|
Hmm; I've adjusted the failing test, but that already fails on the main branch as well: @Test
void tasksWithTypeTest() {
rewriteRun(
//language=groovy
buildGradle(
"""
plugins {
id 'java'
}
tasks.withType(Test) {
}
""",
"""
plugins {
id 'java'
}
tasks.withType(Test) {
useJUnitPlatform()
}
""",
spec -> spec.beforeRecipe(cu -> {
String string = TreeVisitingPrinter.printTree(cu);
System.out.println(string);
JavaType tasksType = ((J.MethodInvocation) cu.getStatements().getLast()).getSelect().getType();
assertTrue(TypeUtils.isAssignableTo("org.gradle.api.tasks.TaskContainer", tasksType), tasksType.toString());
})
)
);
}If I pin back the plugins on the main branch then the above passes; |
Use this link to re-run the recipe: https://app.moderne.io/builder/Sh3Bg6DMd?organizationId=QUxML09wZW4gU291cmNlL09wZW5SZXdyaXRl