Skip to content

Commit 6c0967e

Browse files
committed
make specs
1 parent d431f66 commit 6c0967e

File tree

2 files changed

+48
-1
lines changed

2 files changed

+48
-1
lines changed
Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
# AUTO-GENERATED by tools/checkspecs.py - DO NOT EDIT
2+
from ..reconst import ConstrainedSphericalDeconvolution
3+
4+
5+
def test_ConstrainedSphericalDeconvolution_inputs():
6+
input_map = dict(
7+
algorithm=dict(argstr="%s", mandatory=True, position=-8,),
8+
args=dict(argstr="%s",),
9+
bval_scale=dict(argstr="-bvalue_scaling %s",),
10+
csf_odf=dict(argstr="%s", extensions=None, position=-1,),
11+
csf_txt=dict(argstr="%s", extensions=None, position=-2,),
12+
environ=dict(nohash=True, usedefault=True,),
13+
gm_odf=dict(argstr="%s", extensions=None, position=-3,),
14+
gm_txt=dict(argstr="%s", extensions=None, position=-4,),
15+
grad_file=dict(argstr="-grad %s", extensions=None, xor=["grad_fsl"],),
16+
grad_fsl=dict(argstr="-fslgrad %s %s", xor=["grad_file"],),
17+
in_bval=dict(extensions=None,),
18+
in_bvec=dict(argstr="-fslgrad %s %s", extensions=None,),
19+
in_dirs=dict(argstr="-directions %s", extensions=None,),
20+
in_file=dict(argstr="%s", extensions=None, mandatory=True, position=-7,),
21+
mask_file=dict(argstr="-mask %s", extensions=None,),
22+
max_sh=dict(argstr="-lmax %s", sep=",",),
23+
nthreads=dict(argstr="-nthreads %d", nohash=True,),
24+
shell=dict(argstr="-shell %s", sep=",",),
25+
wm_odf=dict(
26+
argstr="%s", extensions=None, mandatory=True, position=-5, usedefault=True,
27+
),
28+
wm_txt=dict(argstr="%s", extensions=None, mandatory=True, position=-6,),
29+
)
30+
inputs = ConstrainedSphericalDeconvolution.input_spec()
31+
32+
for key, metadata in list(input_map.items()):
33+
for metakey, value in list(metadata.items()):
34+
assert getattr(inputs.traits()[key], metakey) == value
35+
36+
37+
def test_ConstrainedSphericalDeconvolution_outputs():
38+
output_map = dict(
39+
csf_odf=dict(argstr="%s", extensions=None,),
40+
gm_odf=dict(argstr="%s", extensions=None,),
41+
wm_odf=dict(argstr="%s", extensions=None,),
42+
)
43+
outputs = ConstrainedSphericalDeconvolution.output_spec()
44+
45+
for key, metadata in list(output_map.items()):
46+
for metakey, value in list(metadata.items()):
47+
assert getattr(outputs.traits()[key], metakey) == value

tools/checkspecs.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -324,7 +324,7 @@ def test_specs(self, uri):
324324
and "xor" not in trait.__dict__
325325
):
326326
if (
327-
trait.trait_type.__class__.__name__ is "Range"
327+
trait.trait_type.__class__.__name__ == "Range"
328328
and trait.default == trait.trait_type._low
329329
):
330330
continue

0 commit comments

Comments
 (0)