public ParameterIdentificationIdentificationParametersPresenter(IParameterIdentificationIdentificationParametersView view, IIdentificationParameterFactory identificationParameterFactory, IIdentificationParameterToIdentificationParameterDTOMapper identificationParameterDTOMapper, IIdentificationParameterTask identificationParameterTask) : base(view) { _identificationParameterFactory = identificationParameterFactory; _identificationParameterDTOMapper = identificationParameterDTOMapper; _identificationParameterTask = identificationParameterTask; }
protected override void Context() { _identificationParameterDTOMapper = A.Fake <IIdentificationParameterToIdentificationParameterDTOMapper>(); _view = A.Fake <IParameterIdentificationIdentificationParametersView>(); _identificationParameterFactory = A.Fake <IIdentificationParameterFactory>(); _identificationParameterTask = A.Fake <IIdentificationParameterTask>(); sut = new ParameterIdentificationIdentificationParametersPresenter(_view, _identificationParameterFactory, _identificationParameterDTOMapper, _identificationParameterTask); _parameterIdentification = new ParameterIdentification(); _identificationParameter = new IdentificationParameter(); _parameterIdentification.AddIdentificationParameter(_identificationParameter); _identificationParameterDTO = new IdentificationParameterDTO(_identificationParameter); A.CallTo(() => _identificationParameterDTOMapper.MapFrom(_identificationParameter)).Returns(_identificationParameterDTO); A.CallTo(() => _view.BindTo(A <IEnumerable <IdentificationParameterDTO> > ._)) .Invokes(x => _allIdentificationParameterDTO = x.GetArgument <IEnumerable <IdentificationParameterDTO> >(0).ToList()); }