|
4 | 4 |
|
5 | 5 |
|
6 | 6 | def test_ArtifactDetect_inputs(): |
7 | | - input_map = dict(bound_by_brainmask=dict(usedefault=True, |
8 | | - ), |
9 | | - global_threshold=dict(usedefault=True, |
10 | | - ), |
11 | | - ignore_exception=dict(deprecated='1.0.0', |
12 | | - nohash=True, |
13 | | - usedefault=True, |
14 | | - ), |
15 | | - intersect_mask=dict(), |
16 | | - mask_file=dict(), |
17 | | - mask_threshold=dict(), |
18 | | - mask_type=dict(mandatory=True, |
19 | | - ), |
20 | | - norm_threshold=dict(mandatory=True, |
21 | | - xor=['rotation_threshold', 'translation_threshold'], |
22 | | - ), |
23 | | - parameter_source=dict(mandatory=True, |
24 | | - ), |
25 | | - plot_type=dict(usedefault=True, |
26 | | - ), |
27 | | - realigned_files=dict(mandatory=True, |
28 | | - ), |
29 | | - realignment_parameters=dict(mandatory=True, |
30 | | - ), |
31 | | - rotation_threshold=dict(mandatory=True, |
32 | | - xor=['norm_threshold'], |
33 | | - ), |
34 | | - save_plot=dict(usedefault=True, |
35 | | - ), |
36 | | - translation_threshold=dict(mandatory=True, |
37 | | - xor=['norm_threshold'], |
38 | | - ), |
39 | | - use_differences=dict(maxlen=2, |
40 | | - minlen=2, |
41 | | - usedefault=True, |
42 | | - ), |
43 | | - use_norm=dict(requires=['norm_threshold'], |
44 | | - usedefault=True, |
45 | | - ), |
46 | | - zintensity_threshold=dict(mandatory=True, |
47 | | - ), |
| 7 | + input_map = dict( |
| 8 | + bound_by_brainmask=dict(usedefault=True, ), |
| 9 | + global_threshold=dict(usedefault=True, ), |
| 10 | + ignore_exception=dict( |
| 11 | + deprecated='1.0.0', |
| 12 | + nohash=True, |
| 13 | + usedefault=True, |
| 14 | + ), |
| 15 | + intersect_mask=dict(), |
| 16 | + mask_file=dict(), |
| 17 | + mask_threshold=dict(), |
| 18 | + mask_type=dict(mandatory=True, ), |
| 19 | + norm_threshold=dict( |
| 20 | + mandatory=True, |
| 21 | + xor=['rotation_threshold', 'translation_threshold'], |
| 22 | + ), |
| 23 | + parameter_source=dict(mandatory=True, ), |
| 24 | + plot_type=dict(usedefault=True, ), |
| 25 | + realigned_files=dict(mandatory=True, ), |
| 26 | + realignment_parameters=dict(mandatory=True, ), |
| 27 | + rotation_threshold=dict( |
| 28 | + mandatory=True, |
| 29 | + xor=['norm_threshold'], |
| 30 | + ), |
| 31 | + save_plot=dict(usedefault=True, ), |
| 32 | + translation_threshold=dict( |
| 33 | + mandatory=True, |
| 34 | + xor=['norm_threshold'], |
| 35 | + ), |
| 36 | + use_differences=dict( |
| 37 | + maxlen=2, |
| 38 | + minlen=2, |
| 39 | + usedefault=True, |
| 40 | + ), |
| 41 | + use_norm=dict( |
| 42 | + requires=['norm_threshold'], |
| 43 | + usedefault=True, |
| 44 | + ), |
| 45 | + zintensity_threshold=dict(mandatory=True, ), |
48 | 46 | ) |
49 | 47 | inputs = ArtifactDetect.input_spec() |
50 | 48 |
|
51 | 49 | for key, metadata in list(input_map.items()): |
52 | 50 | for metakey, value in list(metadata.items()): |
53 | 51 | assert getattr(inputs.traits()[key], metakey) == value |
54 | | - |
55 | | - |
56 | 52 | def test_ArtifactDetect_outputs(): |
57 | | - output_map = dict(displacement_files=dict(), |
58 | | - intensity_files=dict(), |
59 | | - mask_files=dict(), |
60 | | - norm_files=dict(), |
61 | | - outlier_files=dict(), |
62 | | - plot_files=dict(), |
63 | | - statistic_files=dict(), |
| 53 | + output_map = dict( |
| 54 | + displacement_files=dict(), |
| 55 | + intensity_files=dict(), |
| 56 | + mask_files=dict(), |
| 57 | + norm_files=dict(), |
| 58 | + outlier_files=dict(), |
| 59 | + plot_files=dict(), |
| 60 | + statistic_files=dict(), |
64 | 61 | ) |
65 | 62 | outputs = ArtifactDetect.output_spec() |
66 | 63 |
|
|
0 commit comments