Beispiel #1
0
        private void Be_A_Leap_Year_When_Year_Is_Divisible_By_400()
        {
            // Giwen
            var sut = new Year(4000);

            // When
            var actual = sut.IsLeap();

            // Then
            Assert.True(actual);
        }
Beispiel #2
0
        private void Be_Not_A_Leap_Year_When_Year_Is_Not_Divisible_By_4()
        {
            // Giwen
            var sut = new Year(2015);

            // When
            var actual = sut.IsLeap();

            // Then
            Assert.False(actual);
        }
Beispiel #3
0
        public void is_an_atypical_leap_year()
        {
            var year = new Year();

            year.IsLeap(2000).Should().Be(true);
        }
Beispiel #4
0
        public void is_a_typical_leap_year()
        {
            var year = new Year();

            year.IsLeap(1996).Should().Be(true);
        }
Beispiel #5
0
        public void is_an_atypical_common_year()
        {
            var year = new Year();

            year.IsLeap(2100).Should().Be(false);
        }