public void Init() { this.model = new OLEOPIHealthInsuranceBlock(); var locManager = new Mock<ILocalizationManager>(); locManager.Setup( s => s.GetValidatorTranslationTEST(It.IsAny<string>(), It.IsAny<string>(), It.IsAny<string>())) .Returns("Some test string"); this.validator = new OLEOPIHealthInsuranceBlockValidator(locManager.Object); }
/// <summary> /// Maps from web to db Model /// </summary> /// <param name="input">OLEOPIStayingBlock Web model</param> /// <param name="dbModel">OLEOPIFinancialInformationPage object model</param> private static void ToHealthInsuranceDbModel(OLEOPIHealthInsuranceBlock input, db.OLEOPIFinancialInformationPage dbModel) { if (input == null || dbModel == null) { throw new ArgumentException("One of model is null"); } dbModel.HealthHaveEuropeanHealtInsurance = input.HaveEuropeanHealtInsurance; dbModel.HealthHaveKelaCard = input.HaveKelaCard; dbModel.HealthInsuredForAtLeastTwoYears = input.InsuredForAtLeastTwoYears; dbModel.HealthInsuredForLessThanTwoYears = input.InsuredForLessThanTwoYears; }