public void CalculateNTest_Calculating_ReturnsResultEqualToExpectedOne(double expectedResult, double vm, int round)
        {
            ConfigureParametersCalculator(0, vm);
            var result = DimensionlessCoefficientsCalculator.CalculateN();

            GeneralAssert(expectedResult, result, round);
        }
 public void Setup()
 {
     ParametersOptionsStub               = new Mock <IParametersOptions>(MockBehavior.Default);
     ParametersCalculatorMock            = new Mock <IParametersCalculator>(MockBehavior.Default);
     DimensionlessCoefficientsCalculator = new DimensionlessCoefficientsCalculator(ParametersCalculatorMock.Object);
     ((IParameterised)DimensionlessCoefficientsCalculator).Options = ParametersOptionsStub.Object;
 }
        public void CalculateFTest_FilterCoefficientsLesserThan90AndGreaterThanOrEqual75_Returns2andHalf()
        {
            ParametersOptionsStub.SetupProperty(o => o.FilterCoefficient, 75);
            var result = DimensionlessCoefficientsCalculator.CalculateF();

            GeneralAssert(2.5, result, 1);
        }
        public void CalculateFTest_FilterCoefficientsGreaterThanOrEqual90_Returns2()
        {
            ParametersOptionsStub.SetupProperty(o => o.FilterCoefficient, 90);
            var result = DimensionlessCoefficientsCalculator.CalculateF();

            GeneralAssert(2, result, 0);
        }
 public void CalculateNTest_Calculating_IParametersCalculatorCalculateVmIsCalled()
 {
     DimensionlessCoefficientsCalculator.CalculateN();
     ParametersCalculatorMock.Verify(p => p.CalculateVm());
 }
 public void CalculateDTest_FGreaterThan100_IParametersCalculatorCalculateVmHatchIsCalled()
 {
     ConfigureParametersCalculator(101);
     DimensionlessCoefficientsCalculator.CalculateD();
     ParametersCalculatorMock.Verify(p => p.CalculateVm());
 }