|
| 1 | +# AUTO-GENERATED by tools/checkspecs.py - DO NOT EDIT |
| 2 | +from ...testing import assert_equal |
| 3 | +from ..petpvc import PETPVC |
| 4 | + |
| 5 | + |
| 6 | +def test_PETPVC_inputs(): |
| 7 | + input_map = dict(alpha=dict(argstr='-a %.4f', |
| 8 | + ), |
| 9 | + args=dict(argstr='%s', |
| 10 | + ), |
| 11 | + debug=dict(argstr='-d', |
| 12 | + usedefault=True, |
| 13 | + ), |
| 14 | + environ=dict(nohash=True, |
| 15 | + usedefault=True, |
| 16 | + ), |
| 17 | + fwhm_x=dict(argstr='-x %.4f', |
| 18 | + mandatory=True, |
| 19 | + ), |
| 20 | + fwhm_y=dict(argstr='-y %.4f', |
| 21 | + mandatory=True, |
| 22 | + ), |
| 23 | + fwhm_z=dict(argstr='-z %.4f', |
| 24 | + mandatory=True, |
| 25 | + ), |
| 26 | + ignore_exception=dict(nohash=True, |
| 27 | + usedefault=True, |
| 28 | + ), |
| 29 | + in_file=dict(argstr='-i %s', |
| 30 | + mandatory=True, |
| 31 | + ), |
| 32 | + mask_file=dict(argstr='-m %s', |
| 33 | + mandatory=True, |
| 34 | + ), |
| 35 | + n_deconv=dict(argstr='-k %d', |
| 36 | + ), |
| 37 | + n_iter=dict(argstr='-n %d', |
| 38 | + ), |
| 39 | + out_file=dict(argstr='-o %s', |
| 40 | + genfile=True, |
| 41 | + hash_files=False, |
| 42 | + ), |
| 43 | + pvc=dict(argstr='-p %s', |
| 44 | + mandatory=True, |
| 45 | + ), |
| 46 | + stop_crit=dict(argstr='-a %.4f', |
| 47 | + ), |
| 48 | + terminal_output=dict(nohash=True, |
| 49 | + ), |
| 50 | + ) |
| 51 | + inputs = PETPVC.input_spec() |
| 52 | + |
| 53 | + for key, metadata in list(input_map.items()): |
| 54 | + for metakey, value in list(metadata.items()): |
| 55 | + yield assert_equal, getattr(inputs.traits()[key], metakey), value |
| 56 | + |
| 57 | + |
| 58 | +def test_PETPVC_outputs(): |
| 59 | + output_map = dict(out_file=dict(), |
| 60 | + ) |
| 61 | + outputs = PETPVC.output_spec() |
| 62 | + |
| 63 | + for key, metadata in list(output_map.items()): |
| 64 | + for metakey, value in list(metadata.items()): |
| 65 | + yield assert_equal, getattr(outputs.traits()[key], metakey), value |
0 commit comments