from cascade_at.executor.args.arg_utils import ArgumentList from cascade_at.executor.args.args import DmCommands, DmOptions, ParentLocationID, SexID from cascade_at.executor.args.args import ModelVersionID, BoolArg, LogLevel, StrArg, IntArg from cascade_at.inputs.measurement_inputs import MeasurementInputs from cascade_at.model.grid_alchemy import Alchemy from cascade_at.saver.results_handler import ResultsHandler from cascade_at.settings.settings_config import SettingsConfig from cascade_at.model.priors import Gaussian, _Prior LOG = get_loggers(__name__) ARG_LIST = ArgumentList([ ModelVersionID(), ParentLocationID(), SexID(), DmCommands(), DmOptions(), BoolArg('--fill', help='whether or not to fill the dismod database with data'), BoolArg( '--prior-samples', help='whether or not the prior came from samples or just a mean fit'), IntArg( '--prior-parent', help='the location ID of the parent database to grab the prior for'), IntArg('--prior-sex', help='the sex ID of the parent database to grab prior for'), IntArg('--prior-mulcov', help='the model version id where mulcov stats is passed in', required=False),
def test_sex_id(): a = SexID() assert a._flag == '--sex-id' assert a._parser_kwargs['type'] == int assert a._parser_kwargs['required']