-
Notifications
You must be signed in to change notification settings - Fork 182
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
PoC kotlin data classes #1662
PoC kotlin data classes #1662
Conversation
CLA Assistant Lite bot: Thank you for your submission! Before we can accept your contribution, we ask that you sign our Contributor License Agreement. To sign the CLA, post a comment on this Pull Request that matches the following text exactly: I have read the CLA Document and I hereby sign the CLA You can retrigger this bot by commenting recheck in this Pull Request |
@@ -16,7 +16,7 @@ test: rust | |||
cd oso && mvn $(MVN_FLAGS) clean test | |||
|
|||
package: rust | |||
cd oso && mvn $(MVN_FLAGS) clean package | |||
cd oso && mvn $(MVN_FLAGS) clean install |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just so I could use the locally built 0.26.5-SNAPSHOT
in other projects like a fork of #1655
I built using:
$ MVN_FLAGS=-Dgpg.skip make package
|
||
import static org.junit.jupiter.api.Assertions.*; | ||
|
||
public class OsoJavaRecordTest { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Copy paste of the existing OsoTest
with record User
instead of class User
import org.junit.jupiter.api.Test | ||
import java.util.Set | ||
|
||
class OsoKotlinTest { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(Mostly) output of Intellij "convert to kotlin" of the existing OsoTest
. The use data class...
instead of class
Extending #1661 to also handle querying fields of kotlin data classes.
Uses
PropertyUtils.getProperty
to call thegetFoo()
method generated by kotlin when trying to accessbar.foo
from polar. SeeOsoKotlinTest.kt
for an example.