https://kotlinlang.org logo
r

rbares

04/12/2020, 3:44 PM
Hi, How can I run the tests for the android extensions compiler plugin (in
plugins/android-extensions-compiler
)? I have a patch ready to fix a major bug but can't find a relevant gradle task or IDEA configuration to run the tests. If I can update these tests I hope to raise a pull request within the week
u

udalov

04/14/2020, 3:20 PM
Note that JVM IR backend will not be enabled by default in the upcoming Kotlin 1.4. There will be a compiler option to enable it. That option would also "poison" the generated classes in the sense that they will not be usable from the current JVM backend. Which is fine for applications, but unacceptable for libraries, for example. We're aiming to enable JVM IR as default in Kotlin 1.5. So if you're ready to use that option, you can simply switch to the JVM IR backend in 1.4, and use the new Parcelable plugin by Steven (which will be merged by then). Otherwise, and if it is critical for you, I do recommend to send a PR with changes in the old backend
👍 1
r

rbares

04/14/2020, 10:09 PM
That is insightful thank you for clarifying. Would you be able to advise who best to speak to regarding the issue I am having with the existing tests?
u

udalov

04/16/2020, 12:03 PM
I think you can just right-click on the specific test, or the whole directory in IntelliJ IDEA and run everything there. Or if you prefer command line, something like this should work:
./gradlew cleanTest :plugins:android-extensions-compiler:test
r

rbares

04/19/2020, 5:08 PM
Unfortunately Steven has confirmed that these tests are broken on master. He has provided a fix for the runners in https://github.com/JetBrains/kotlin/pull/3271/commits/e3c3e67e687f84886882048e7e339c28166b5056 . I have confirmed that part of this diff enables the tests to run for my changes. I am happy to do a partial cherry-pick for the relevant sections, with attribution to Stevens branch. Would you have a preferred approach?
As Steven was happy with the partial cherry-pick the PR is now up https://github.com/JetBrains/kotlin/pull/3316
u

udalov

04/21/2020, 1:40 PM
Sorry for the delay! Actually I was looking forward to merge Steven's changes to master soon. I hope it's alright for you to rebase on them after that.
r

rbares

04/21/2020, 2:57 PM
Sure I certainly don't mind which order these go in, and it will clean up the diff a little also!