-
Notifications
You must be signed in to change notification settings - Fork 25
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
Adding tests that show errors in deserialization #125
Conversation
### What's done: - test for invalid custom serialization - test for invalid inline serialization
…x/invalid-traversal � Conflicts: � ktoml-core/src/commonTest/kotlin/com/akuleshov7/ktoml/decoders/InlineDecoderTest.kt
85bb617
to
0d1b848
Compare
data class Settings(val background: SingleProperty, val foreground: SingleProperty) | ||
|
||
@Test | ||
@Ignore |
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.
This test does not work, but I actually would have expected it be working
class Color(val rgb: Int) | ||
|
||
@Test | ||
@Ignore |
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.
This is the example from https://github.com/Kotlin/kotlinx.serialization/blob/master/docs/serializers.md#composite-serializer-via-surrogate
Also not working
…ov7/ktoml into bugfix/invalid-traversal � Conflicts: � ktoml-core/src/commonMain/kotlin/com/akuleshov7/ktoml/decoders/TomlMainDecoder.kt
@bishiboosh @NightEule5 this is a very small PR with a workaround for custom serializers (with the override of I hope you don't mind if I merge it without the review as it is very primitive - just a small hack. I also have found that some more complex cases are not working, so I have added tests and ignored them |
What's done: