Skip to content
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

RewriteTest for TempDir and cleanup unused imports & deprecations #253

Merged
merged 4 commits into from
Aug 21, 2022
Merged

RewriteTest for TempDir and cleanup unused imports & deprecations #253

merged 4 commits into from
Aug 21, 2022

Conversation

timtebeek
Copy link
Contributor

Based on feedback received in #252 (comment)

JavaRecipeTest is being replaced with RewriteTest

@timtebeek
Copy link
Contributor Author

No idea where the sudden test failure might be coming from:

JUnitFailToAssertJFailTest > inlineReference() FAILED
    java.lang.AssertionError: Failed to run parse sources or recipe
        at org.openrewrite.RecipeTest$DefaultImpls._get_executionContext_$lambda-0(RecipeTest.kt:36)
        at org.openrewrite.RecipeTest$DefaultImpls$$Lambda$442/0x000000080122db18.accept(Unknown Source)
        at org.openrewrite.RecipeScheduler.lambda$scheduleVisit$5(RecipeScheduler.java:244)
        at org.openrewrite.RecipeScheduler$$Lambda$578/0x0000000801346610.apply(Unknown Source)
        at org.openrewrite.RecipeScheduler.lambda$mapAsync$0(RecipeScheduler.java:49)
        at org.openrewrite.RecipeScheduler$$Lambda$579/0x0000000801346880.call(Unknown Source)
        at org.openrewrite.scheduling.DirectScheduler.schedule(DirectScheduler.java:35)
        at org.openrewrite.RecipeScheduler.mapAsync(RecipeScheduler.java:50)
        at org.openrewrite.RecipeScheduler.scheduleVisit(RecipeScheduler.java:190)
        at org.openrewrite.RecipeTest$RecipeSchedulerCheckingExpectedCycles.scheduleVisit(RecipeTest.kt:218)
        at org.openrewrite.RecipeScheduler.scheduleRun(RecipeScheduler.java:86)
        at org.openrewrite.Recipe.run(Recipe.java:287)
        at org.openrewrite.RecipeTest$DefaultImpls.assertChangedBase(RecipeTest.kt:108)
        at org.openrewrite.RecipeTest$DefaultImpls.assertChangedBase(RecipeTest.kt:57)
        at org.openrewrite.java.JavaRecipeTest$DefaultImpls.assertChanged(JavaRecipeTest.kt:66)
        at org.openrewrite.java.testing.assertj.JUnitFailToAssertJFailTest.assertChanged(JUnitFailToAssertJFailTest.kt:23)
        at org.openrewrite.java.JavaRecipeTest$DefaultImpls.assertChanged$default(JavaRecipeTest.kt:49)
        at org.openrewrite.java.testing.assertj.JUnitFailToAssertJFailTest.inlineReference(JUnitFailToAssertJFailTest.kt:161)

        Caused by:
        org.openrewrite.UncaughtVisitorException: java.lang.IllegalStateException: Unable to construct Java11Parser.
            at app//org.openrewrite.TreeVisitor.visit(TreeVisitor.java:253)
            at app//org.openrewrite.TreeVisitor.visit(TreeVisitor.java:145)
            at app//org.openrewrite.java.JavaTemplate.withTemplate(JavaTemplate.java:520)
            at app//org.openrewrite.java.JavaTemplate.withTemplate(JavaTemplate.java:42)
            at app//org.openrewrite.java.tree.J.withTemplate(J.java:82)
            at app//org.openrewrite.java.testing.assertj.JUnitFailToAssertJFail$JUnitFailToAssertJFailVisitor$UnqualifiedMethodInvocations.visitMethodInvocation(JUnitFailToAssertJFail.java:143)
            at app//org.openrewrite.java.testing.assertj.JUnitFailToAssertJFail$JUnitFailToAssertJFailVisitor$UnqualifiedMethodInvocations.visitMethodInvocation(JUnitFailToAssertJFail.java:122)
            at app//org.openrewrite.java.tree.J$MethodInvocation.acceptJava(J.java:3414)

No relevant changes made, and does not show up locally, although we've seen some more Unable to construct Java11Parser failures in this project lately.

@jkschneider jkschneider merged commit aa92c0a into openrewrite:main Aug 21, 2022
@timtebeek timtebeek deleted the tempdir_rewritetest_and_cleanup branch August 21, 2022 16:12
@tkvangorder tkvangorder added this to the 1.27.0 milestone Sep 2, 2022
@tkvangorder tkvangorder added the enhancement New feature or request label Sep 2, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

3 participants