Beispiel #1
0
        public void Test_validate_with_good_data_returns_true(Weather weather)
        {
            // Arrange.
            // Act.
            var result = _weatherValidator.Validate(weather);

            // Assert.
            result.IsValid.Should().BeTrue("the weather data is all made up of valid data.");
        }
Beispiel #2
0
        public static ValidationResult IsValid(this Weather weather)
        {
            var validator = new WeatherValidator();

            var result = validator.Validate(weather);

            return(result);
        }