Open kevinb9n opened 2 years ago
Yes!
I meant to comment on the original PR but it landed before I had a chance. I wrote about this a bit here. Gradle makes this super easy. Set your toolchain to 18 (19 in a few weeks!) and create a test task for each JDK in your supported range.
Whoa thanks, that's perfectly helpful!
I don't understand build stuff, but I ?think? that currently:
-source 8 -target 8
to make sure the JAR is 8-compatibleBut isn't the only thing that we really need to splay out to multiple JDKs for tests? More to the point: since we will only be releasing one artifact, shouldn't these should all test against the exact same single jar -- the one we will actually publish?
So I'm wondering if for purposes of compilation we can/should hardcode a JDK version? And if we do the same thing for the javadoc generation (setting it to say 17) it would fix the current issue that it's failing on JDK 11.
As for running tests though, I suppose it's okay to keep working as it has been? I don't know what the tradeoffs would be of moving to one distinct more-hermetic gradle target for each.