-
Notifications
You must be signed in to change notification settings - Fork 32
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
Overload isempty method for types.untyped.Set (Issue #561) #616
base: master
Are you sure you want to change the base?
Conversation
The following snippet causes a lot of tests to fail, but is not relevant anymore: Lines 66 to 70 in 3222f33
The code was embedded in this context: %immediately elide prefix all property names with this but only if there are
%no typed objects in it.
propnames = keys(props);
if hasTypes
parsed = containers.Map({root}, {props});
else
parsed = containers.Map;
for i=1:length(propnames)
pnm = propnames{i};
p = props(pnm);
parsed([root '_' pnm]) = p;
end
end
if isempty(parsed)
%special case where a directory is simply empty. Return itself but
%empty
parsed(root) = [];
end It was possible to create a containers.Map object named Lines 56 to 63 in 5aa27d9
Code coverage also shows that lines are not covered by tests. Will remove this part |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #616 +/- ##
==========================================
+ Coverage 90.91% 90.95% +0.04%
==========================================
Files 107 107
Lines 4753 4752 -1
==========================================
+ Hits 4321 4322 +1
+ Misses 432 430 -2 ☔ View full report in Codecov by Sentry. |
Current thinking: This should be not be merged as is. A The same should be true for the Set. Instead of redefining is empty, I think it would be better to not override size as is currently done, and also to change the custom display for a Set with no elements from: |
Fix #561
Motivation
See issue #561
How to test the behavior?
Checklist
fix #XX
whereXX
is the issue number?