Add unit tests for ActorObjectSerializer#1790
Open
manduinca wants to merge 1 commit into
Open
Conversation
Covers the previously untested paths of ActorObjectSerializer: actor timer deserialization (including the data attribute and missing optional attributes), null handling in serialize and deserialize, actor runtime config serialization with all attributes and per-type configs, and the default serialization pass-through for custom types. Part of dapr#369 Signed-off-by: Jean Pierre Mandujano G. <jeanpierre.mandujano@gmail.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #1790 +/- ##
============================================
+ Coverage 76.89% 76.99% +0.09%
- Complexity 2300 2306 +6
============================================
Files 244 244
Lines 7145 7145
Branches 748 748
============================================
+ Hits 5494 5501 +7
+ Misses 1285 1284 -1
+ Partials 366 360 -6 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Adds a dedicated unit test class for
ActorObjectSerializerinsdk-actors. This serializer had no test of its own, and the timer deserialization path (ActorTimerParams) had no coverage at all.The 10 new tests cover: null handling in
serialize/deserialize, timer serialization including thedatafield (base64), timer round trips with and without data, timer JSON with missing optional attributes,ActorRuntimeConfigserialization with all attributes and per-typeentitiesConfig, and default pass-through for custom types.ActorRuntimeTestandActorProxyImplTestalready grew a lot since the issue was filed, so this PR is scoped to the remaining gap.Verified locally with
./mvnw -pl sdk-actors -am install -DskipITs=true: 159 tests in the module, 0 failures. Checkstyle clean.Issue reference
Part of #369
Checklist