[codex] add interp regression coverage for recent marshaling changes#40
Merged
Merged
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #40 +/- ##
==========================================
+ Coverage 54.79% 54.82% +0.03%
==========================================
Files 57 57
Lines 10677 10677
==========================================
+ Hits 5850 5854 +4
+ Misses 4174 4171 -3
+ Partials 653 652 -1 ☔ View full report in Codecov by Sentry. 🚀 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.
What changed
TestInterpreter_Alloc/interns stringsto cover the recentInterpreter.Alloc(types.String)interning pathTestInterpreter_Unmarshal/host object pointer targetto cover round-tripping pointer-hostable defined scalars after HostObject mutationWhy
Recent marshaling changes introduced new behavior for pointer-hostable defined scalars and direct string interning in the interpreter heap. These paths were changed recently but were not protected by focused regression tests.
Validation
go test ./interp -run 'TestInterpreter_(Alloc|Unmarshal)$'go test ./interpmake lintChanged paths tested
interp/interp.go: direct string interning throughAllocand release cleanupinterp/marshal.go: pointer-hostable scalarHostObjectunmarshaling pathinterp/interp_test.goSkipped targets
types/map.goand threaded map fast paths: recent map refactor already added broad package coverage nearby; I did not find a smaller changed branch with a clearer fail-before regression than the interp marshaling paths above.marshal.gohelper branches: several remaining uncovered helpers are generic error or unsupported-type paths and would require more synthetic setup than warranted for this narrow coverage pass.