Add a unit test for join method coverage#630
Merged
adnanhemani merged 2 commits intodata-8:masterfrom Oct 7, 2025
Merged
Conversation
adnanhemani
requested changes
May 24, 2025
Member
adnanhemani
left a comment
There was a problem hiding this comment.
I'm not really in favor of testing in such roundabout ways. If we have dead code, I would much rather remove it instead.
Contributor
Author
davidwagner
approved these changes
Jun 3, 2025
Member
|
@adnanhemani I'll let you comment, but it looks reasonable to me. |
adnanhemani
approved these changes
Oct 7, 2025
Member
adnanhemani
left a comment
There was a problem hiding this comment.
LGTM - thanks for this change!
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.
[O] Wrote test for feature
[ ] Added changes to CHANGELOG.md
[ ] Bumped version number (delete if unneeded)
Changes proposed:
Hello, I'm a student and a first-time contributor.
One of the coverage missing in 'tables.py' is in the '_join' internal method, in lines 2039-2040 where it checks for an empty table. However, the 'join' method for external interface already has these checks in lines 2024-2025, preventing those lines from being covered. This makes it difficult to test '_join' by just calling 'join' as discussed in this PR.
In this unit test, I decided to modify the 'join' method to skip those checks and allow '_join' to be covered. This way, the functionality of _join can be tested without directly invoking it.
Please let me know if any changes are needed to improve this implementation.