Skip to content

Commit 92856e3

Browse files
author
Steven Tilley
committed
Add test case for notop
1 parent 8f6b584 commit 92856e3

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed

heudiconv/tests/test_heuristics.py

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -150,3 +150,23 @@ def test_scout_conversion(tmpdir):
150150
'ses-localizer/anat/sub-phantom1sid1_ses-localizer_scout.dicom.tgz'
151151
)
152152
)
153+
154+
155+
@pytest.mark.parametrize(
156+
'bidsoptions', [
157+
['notop'], [],
158+
])
159+
def test_notop(tmpdir, bidsoptions):
160+
tmppath = tmpdir.strpath
161+
args = (
162+
"-f reproin --files %s"
163+
% (TESTS_DATA_PATH)
164+
).split(' ') + ['-o', tmppath] + ['-b'] + bidsoptions
165+
runner(args)
166+
167+
assert op.exists(pjoin(tmppath, 'Halchenko/Yarik/950_bids_test4'))
168+
for fname in ['CHANGES', 'dataset_description.json', 'participants.tsv', 'README']:
169+
if 'notop' in bidsoptions:
170+
assert not op.exists(pjoin(tmppath, 'Halchenko/Yarik/950_bids_test4', fname))
171+
else:
172+
assert op.exists(pjoin(tmppath, 'Halchenko/Yarik/950_bids_test4', fname))

0 commit comments

Comments
 (0)