public void Validate_ValidDistribution_NoErrorMessage()
        {
            // Setup
            var rule = new VariationCoefficientNormalDistributionRule(new VariationCoefficientNormalDistribution(2),
                                                                      paramName);

            // Call
            IEnumerable <string> message = rule.Validate();

            // Assert
            CollectionAssert.IsEmpty(message);
        }
        public void ValidateDistribution_InvalidVariationCoefficient_ErrorMessage(double value)
        {
            // Setup
            var distribution = new VariationCoefficientNormalDistribution(2)
            {
                CoefficientOfVariation = (RoundedDouble)value
            };

            var rule = new VariationCoefficientNormalDistributionRule(distribution, paramName);

            // Call
            IEnumerable <string> messages = rule.Validate();

            string[] validationMessages = messages.ToArray();

            // Assert
            Assert.AreEqual(1, validationMessages.Length);
            string expectedMessage = $"De variatiecoëfficiënt voor '{paramName}' moet groter zijn dan of gelijk zijn aan 0.";

            StringAssert.StartsWith(expectedMessage, validationMessages[0]);
        }
        public void Validate_InvalidMean_ErrorMessage(double value)
        {
            // Setup
            var distribution = new VariationCoefficientNormalDistribution(2)
            {
                Mean = (RoundedDouble)value
            };

            var rule = new VariationCoefficientNormalDistributionRule(distribution, paramName);

            // Call
            IEnumerable <string> messages = rule.Validate();

            string[] validationMessages = messages.ToArray();

            // Assert
            Assert.AreEqual(1, validationMessages.Length);
            string expectedMessage = $"De verwachtingswaarde voor '{paramName}' moet een concreet getal zijn.";

            StringAssert.StartsWith(expectedMessage, validationMessages[0]);
        }