# AUTO-GENERATED by tools/checkspecs.py - DO NOT EDIT
from ....testing import assert_equal
from ..minc import Beast


def test_Beast_inputs():
    input_map = dict(abspath=dict(argstr='-abspath',
    usedefault=True,
    ),
    args=dict(argstr='%s',
    ),
    clobber=dict(argstr='-clobber',
    usedefault=True,
    ),
    confidence_level_alpha=dict(argstr='-alpha %s',
    ),
    configuration_file=dict(argstr='-configuration %s',
    ),
    environ=dict(nohash=True,
    usedefault=True,
    ),
    fill_holes=dict(argstr='-fill',
    ),
    flip_images=dict(argstr='-flip',
    ),
    ignore_exception=dict(nohash=True,
    usedefault=True,
    ),
    input_file=dict(argstr='%s',
    mandatory=True,
    position=-2,
    ),
    library_dir=dict(argstr='%s',
    mandatory=True,
    position=-3,
    ),
    load_moments=dict(argstr='-load_moments',
    ),
    median_filter=dict(argstr='-median',
    ),
    nlm_filter=dict(argstr='-nlm_filter',
    ),
    number_selected_images=dict(argstr='-selection_num %s',
    ),
    output_file=dict(argstr='%s',
    hash_files=False,
    name_source=['input_file'],
    name_template='%s_beast_mask.mnc',
    position=-1,
    ),
    patch_size=dict(argstr='-patch_size %s',
    ),
    probability_map=dict(argstr='-probability',
    ),
    same_resolution=dict(argstr='-same_resolution',
    ),
    search_area=dict(argstr='-search_area %s',
    ),
    smoothness_factor_beta=dict(argstr='-beta %s',
    ),
    terminal_output=dict(nohash=True,
    ),
    threshold_patch_selection=dict(argstr='-threshold %s',
    ),
    voxel_size=dict(argstr='-voxel_size %s',
    ),
    )
    inputs = Beast.input_spec()

    for key, metadata in list(input_map.items()):
        for metakey, value in list(metadata.items()):
            yield assert_equal, getattr(inputs.traits()[key], metakey), value


def test_Beast_outputs():
    output_map = dict(output_file=dict(),
    )
    outputs = Beast.output_spec()

    for key, metadata in list(output_map.items()):
        for metakey, value in list(metadata.items()):
            yield assert_equal, getattr(outputs.traits()[key], metakey), value
