Testing Infrastructure that is easy to use in IDEs other than IntelliJ #304
-
The testing infrastructure in rewrite-test is very Kotlin-centric and works well when using IntelliJ, however, this can make it more difficult for those attempting to evaluate Rewrite's capabilities when they are not using IntelliJ. I think with minimal effort we could provide a seamless testing experience for those wanting to use a pure-Java testing approach.
|
Beta Was this translation helpful? Give feedback.
Replies: 3 comments
-
My interpretation of this is that authoring tests in Java should be possible. Which means a plain old Java base for tests. I expect we can do this in a way that, probably via kotlin extension methods, none of our test classes would have to change. |
Beta Was this translation helpful? Give feedback.
-
assertChanged(
before = """
...
""",
after = """
...
"""
) |
Beta Was this translation helpful? Give feedback.
-
There's now a RewriteTest.java, which does not require Kotlin to write tests; We're transitioning to Java 17 for tests, to take advantage of text blocks, and slowly converting project tests from Kotlin to Java. That ought to help developers setup IDEs other than IntelliJ, although the recommended IDE remains IntelliJ, as also indicated in CONTRIBUTORS.md. |
Beta Was this translation helpful? Give feedback.
There's now a RewriteTest.java, which does not require Kotlin to write tests; We're transitioning to Java 17 for tests, to take advantage of text blocks, and slowly converting project tests from Kotlin to Java.
That ought to help developers setup IDEs other than IntelliJ, although the recommended IDE remains IntelliJ, as also indicated in CONTRIBUTORS.md.