public void UpdateRetentionTestFailTest()
        {
            var testBll = MockHelperBll.GetTestBllForSavingAndUpdating(null, null, null);
            var target  = new InkoRetentionServiceHelper(new NLogLoggerFactory())
            {
                TestBll = testBll
            };

            var actual = target.UpdateRetentionTest(new InkoRetentionEditViewModel());

            Assert.Equal(null, actual);
        }
        public void UpdateRetentionTestBaseTest()
        {
            var viewModel = GetViewModelTestData();
            var testValueReturnedFromDb = GetTestValueTestData();

            testValueReturnedFromDb.CreatedPerson            = "Fritz";
            testValueReturnedFromDb.LastEditedPerson         = "Fritz";
            testValueReturnedFromDb.IncontinencePadTestValue = new IncontinencePadTestValue
            {
                IncontinencePadTime = new TimeSpan(11, 11, 0),
                TestType            = TestTypeIncontinencePad.Retention
            };

            var testSheetDataFromDb       = GetTestSheetTestData();
            var productionOrderDataFromDb = GetProductionOrderTestData();

            var babyDiaperBll = MockHelperBll.GetTestBllForSavingAndUpdating(testSheetDataFromDb, productionOrderDataFromDb, testValueReturnedFromDb);

            var testServiceHelper = MockHelperTestServiceHelper.GetTestServiceHelperForUpdating();

            var target = new InkoRetentionServiceHelper(new NLogLoggerFactory())
            {
                TestBll           = babyDiaperBll,
                TestServiceHelper = testServiceHelper
            };

            var actual = target.UpdateRetentionTest(viewModel);

            Assert.Equal(testValueReturnedFromDb, actual);
            Assert.Equal(30.21, actual.IncontinencePadTestValue.RetentionWeight);
            Assert.Equal(430.15, actual.IncontinencePadTestValue.RetentionWetValue);
            Assert.Equal(212.11, actual.IncontinencePadTestValue.RetentionAfterZentrifuge);
            Assert.Equal(399.94, actual.IncontinencePadTestValue.RetentionAbsorbtion, 2);
            Assert.Equal(181.9, actual.IncontinencePadTestValue.RetentionEndValue, 2);
            Assert.Equal("Hans", actual.LastEditedPerson);
            Assert.Equal("Fritz", actual.CreatedPerson);
            Assert.NotEqual(new DateTime(2016, 1, 2), actual.LastEditedDateTime);
        }