Skip to content

Commit bea0640

Browse files
authored
[FIX] run test create roi octave (#1285)
* run test create roi octave * fix several tests in cpp roi * reset submod * update CPP_ROI * fix default path output create roi * fix typo
1 parent 63de6d0 commit bea0640

File tree

4 files changed

+9
-23
lines changed

4 files changed

+9
-23
lines changed

src/bidspm/bidspm.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@ def create_roi(
186186
) -> str:
187187
roi_name = "{ '" + "', '".join(roi_name) + "' }" if roi_name is not None else None # type: ignore
188188
if roi_dir is None:
189-
roi_dir = Path()
189+
roi_dir = output_dir
190190

191191
cmd = generate_cmd(
192192
bids_dir=bids_dir,

src/workflows/roi/bidsCreateROI.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ function bidsCreateROI(opt)
1414
% opt.roi.atlas = 'wang';
1515
% opt.roi.hemi = {'L', 'R'};
1616
% opt.roi.name = {'V1v', 'V1d'};
17-
% opt.roi.space = {'IXI549Space''};
17+
% opt.roi.space = {'IXI549Space'};
1818
%
1919
% bidsCreateROI(opt);
2020
%

tests/tests_slow/tests_cli/test_bidspm_create_roi.m

Lines changed: 6 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,6 @@ function test_bidsCreateROI_boilerplate_only()
1313

1414
markTestAs('slow');
1515

16-
if bids.internal.is_octave
17-
moxunit_throw_test_skipped_exception('Need bug fix in CPP ROI extractRoiFromAtlas.');
18-
end
19-
2016
outputPath = tempName();
2117

2218
bidspm(pwd, outputPath, ...
@@ -40,10 +36,6 @@ function test_bidsCreateROI_glasser()
4036

4137
markTestAs('slow');
4238

43-
if bids.internal.is_octave
44-
moxunit_throw_test_skipped_exception('Need bug fix in CPP ROI extractRoiFromAtlas.');
45-
end
46-
4739
outputPath = tempName();
4840

4941
bidspm(pwd, outputPath, ...
@@ -54,6 +46,12 @@ function test_bidsCreateROI_glasser()
5446
'space', {'IXI549Space'}, ...
5547
'verbosity', 3);
5648

49+
assert(exist(fullfile(outputPath, ...
50+
'derivatives', ...
51+
'bidspm-roi', ...
52+
'reports', ...
53+
'create_roi_atlas-glasser_citation.md'), 'file') == 2);
54+
5755
rois = spm_select('FPList', fullfile(outputPath, ...
5856
'derivatives', ...
5957
'bidspm-roi', 'group'), '.*glasser.*_mask\.nii');
@@ -65,10 +63,6 @@ function test_bidsCreateROI_wang()
6563

6664
markTestAs('slow');
6765

68-
if bids.internal.is_octave
69-
moxunit_throw_test_skipped_exception('Need bug fix in CPP ROI extractRoiFromAtlas.');
70-
end
71-
7266
outputPath = tempName();
7367

7468
bidspm(pwd, outputPath, ...
@@ -90,10 +84,6 @@ function test_bidsCreateROI_neuromorphometrics()
9084

9185
markTestAs('slow');
9286

93-
if bids.internal.is_octave
94-
moxunit_throw_test_skipped_exception('Need bug fix in CPP ROI extractRoiFromAtlas.');
95-
end
96-
9787
outputPath = tempName();
9888

9989
bidspm(pwd, outputPath, ...
@@ -133,10 +123,6 @@ function test_bidsCreateROI_one_hemisphere()
133123

134124
markTestAs('slow');
135125

136-
if bids.internal.is_octave
137-
moxunit_throw_test_skipped_exception('Need bug fix in CPP ROI extractRoiFromAtlas.');
138-
end
139-
140126
outputPath = tempName();
141127

142128
bidspm(pwd, outputPath, 'subject', ...

0 commit comments

Comments
 (0)