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

[MAINT] transfer test to bids validator #1081

Merged
merged 4 commits into from
Aug 15, 2024
Merged

Conversation

Remi-Gau
Copy link
Contributor

companion PR to bids-standard/python-validator#8

there are more than 600 lines of test that are commented: should I bother transferring them to the other repo too?

Copy link

codecov bot commented Aug 14, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 89.72%. Comparing base (d66be75) to head (f286231).
Report is 5 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1081      +/-   ##
==========================================
- Coverage   89.81%   89.72%   -0.09%     
==========================================
  Files          63       63              
  Lines        7174     7123      -51     
  Branches     1373     1363      -10     
==========================================
- Hits         6443     6391      -52     
- Misses        532      533       +1     
  Partials      199      199              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Comment on lines 889 to 863
def test_layout_with_validation():
data_dir = join(get_test_data_path(), '7t_trt')
layout1 = BIDSLayout(data_dir, validate=True)
layout2 = BIDSLayout(data_dir, validate=False)
assert len(layout1.files) < len(layout2.files)
# Not a valid BIDS file
badfile = join(data_dir, 'test.bval')
assert badfile not in layout1.files
assert badfile in layout2.files
Copy link
Collaborator

Choose a reason for hiding this comment

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

Unless this test exists elsewhere, it's worth keeping.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

ah yes true

good catch

@effigies
Copy link
Collaborator

there are more than 600 lines of test that are commented: should I bother transferring them to the other repo too?

The bad values might be worth it, just as assert not validator.is_bids(). The good values, I don't think so.

@Remi-Gau
Copy link
Contributor Author

there are more than 600 lines of test that are commented: should I bother transferring them to the other repo too?

The bad values might be worth it, just as assert not validator.is_bids(). The good values, I don't think so.

OK I will try to transfer those then.

@Remi-Gau
Copy link
Contributor Author

will merge #1080 before this one

@effigies effigies merged commit de039c2 into bids-standard:master Aug 15, 2024
24 checks passed
@Remi-Gau Remi-Gau deleted the test branch August 15, 2024 12:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants