Skip to content
This repository was archived by the owner on Jun 9, 2025. It is now read-only.

Conversation

@ArnyminerZ
Copy link
Member

Closes #88

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>
@ArnyminerZ ArnyminerZ added the bug Something isn't working label Mar 31, 2023
@ArnyminerZ ArnyminerZ requested a review from rfc2822 March 31, 2023 15:23
@ArnyminerZ ArnyminerZ self-assigned this Mar 31, 2023
@ArnyminerZ ArnyminerZ linked an issue Mar 31, 2023 that may be closed by this pull request
@ArnyminerZ ArnyminerZ marked this pull request as ready for review March 31, 2023 15:23
Copy link
Member

@rfc2822 rfc2822 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please also add the corresponding test and set then to ready when everything is complete :)

@rfc2822 rfc2822 marked this pull request as draft March 31, 2023 15:30
Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>
@ArnyminerZ ArnyminerZ marked this pull request as ready for review March 31, 2023 16:28
@ArnyminerZ
Copy link
Member Author

@rfc2822 Is this enough?

@rfc2822
Copy link
Member

rfc2822 commented Apr 1, 2023

@rfc2822 Is this enough?

The tested method is in AndroidEvent, so the test should be in AndroidEventTest.

I think it should be named testBuildUnknownProperty_NoValue(), directly below testBuildUnknownProperty() and similar to that test.

However instead of adding a working unknown parameter, our test should add the unknown property without value (only the unknown parameter, without the rest of the ICalendar). buildEvent() then will call the insert method (which will call our changed method), so we make sure that it doesn't throw an exception. firstUnknownProperty should then return null.

Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>
Signed-off-by: Arnau Mora <arnyminer.z@gmail.com>
@ArnyminerZ ArnyminerZ requested a review from rfc2822 April 3, 2023 09:33
Copy link
Member

@rfc2822 rfc2822 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, very good now. Test fails without the fix and passes with the fix :)

@rfc2822 rfc2822 merged commit f9705ff into main Apr 3, 2023
@rfc2822 rfc2822 deleted the 88-unknownproperty-handle-null-values branch April 3, 2023 13:55
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

UnknownProperty: handle null values

2 participants