Skip to content
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

[Code Coverage] loader/test_dataloader.py #6648

Merged
merged 9 commits into from
Feb 9, 2023
Merged

Conversation

sivonxay
Copy link
Contributor

@sivonxay sivonxay commented Feb 8, 2023

Previously, tests for DataLoader and Collater only covered input datasets composed of Data or HeteroData. This commit adds a testing function that tests inputs of type:

  • Sequence[torch.Tensor]
  • Sequence[int]
  • Sequence[float]
  • Sequence[Mapping]
  • Sequence[tuple]
  • Sequence[Sequence]

sivonxay and others added 3 commits January 30, 2023 15:29
Tests for torch_geometric.loader.dataloader.Collater only covered inputs of type List[torch_geometric.data.Data] and List[torch_geometric.data.HeteroData]. This commit adds a testing function that tests inputs of List[torch.Tensor], ]List[int], List[float], List[Mapping], List[tuple], and List[Sequence].
@codecov
Copy link

codecov bot commented Feb 8, 2023

Codecov Report

Merging #6648 (bd721b5) into master (1cd0f46) will increase coverage by 0.04%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master    #6648      +/-   ##
==========================================
+ Coverage   87.76%   87.81%   +0.04%     
==========================================
  Files         422      422              
  Lines       22906    22907       +1     
==========================================
+ Hits        20103    20115      +12     
+ Misses       2803     2792      -11     
Impacted Files Coverage Δ
torch_geometric/nn/model_hub.py 100.00% <ø> (ø)
torch_geometric/nn/__init__.py 100.00% <100.00%> (ø)
torch_geometric/nn/inits.py 75.00% <0.00%> (+7.14%) ⬆️
torch_geometric/loader/dataloader.py 100.00% <0.00%> (+18.91%) ⬆️

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

test/loader/test_dataloader.py Outdated Show resolved Hide resolved
test/loader/test_dataloader.py Outdated Show resolved Hide resolved
Copy link
Member

@wsad1 wsad1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants