You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Given that null references cause so much unexpected trouble, what about reporting untested entry points that could cause nil point panics on the code coverage report?
This could be limited to public functions and show as a small flag on the HTML reports.
Example:
...varprojects, err=repo.GetProjects() [nil]
...
where [nil] would actually be a report flag saying this code wasn't covered with a nil return for this value.
This is not the purpose of the test coverage tool. If you want to build a tool that does this and use the coverage UI, the code is there for the taking.
Given that null references cause so much unexpected trouble, what about reporting untested entry points that could cause nil point panics on the code coverage report?
This could be limited to public functions and show as a small flag on the HTML reports.
Example:
where
[nil]
would actually be a report flag saying this code wasn't covered with a nil return for this value.Reference: Null References: The Billion Dollar Mistake
The text was updated successfully, but these errors were encountered: