Skip to content

Commit 76697c5

Browse files
committed
Address review comment and update auto_FitTensor test
1 parent 67cfe04 commit 76697c5

File tree

2 files changed

+7
-8
lines changed

2 files changed

+7
-8
lines changed

nipype/interfaces/mrtrix3/base.py

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,7 @@
1111

1212

1313
class Info(PackageInfo):
14-
version_cmd = which('mrconvert')
15-
if version_cmd:
16-
version_cmd = version_cmd + ' --version'
14+
version_cmd = 'mrconvert --version'
1715

1816
@staticmethod
1917
def parse_version(raw_info):
@@ -36,11 +34,7 @@ def looseversion(cls):
3634
3735
If no version found, use LooseVersion('0.0.0')
3836
"""
39-
ver = cls.version()
40-
if ver is None:
41-
return LooseVersion('0.0.0')
42-
43-
return cls.version())
37+
return LooseVersion(cls.version() or '0.0.0')
4438

4539

4640
class MRTrix3BaseInputSpec(CommandLineInputSpec):

nipype/interfaces/mrtrix3/tests/test_auto_FitTensor.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,11 @@ def test_FitTensor_inputs():
3232
position=-1,
3333
usedefault=True,
3434
),
35+
reg_term=dict(
36+
argstr='-regularisation %f',
37+
max_ver='0.3.13',
38+
usedefault=True,
39+
),
3540
)
3641
inputs = FitTensor.input_spec()
3742

0 commit comments

Comments
 (0)