public void GetDaysInYearCrossCheck()
 {
     var calculator = new HebrewYearMonthDayCalculator(HebrewMonthNumbering.Civil);
     for (int year = calculator.MinYear; year <= calculator.MaxYear; year++)
     {
         int sum = Enumerable.Range(1, calculator.GetMonthsInYear(year))
                             .Sum(month => calculator.GetDaysInMonth(year, month));
         Assert.AreEqual(sum, calculator.GetDaysInYear(year), "Days in {0}", year);
     }
 }
 public void DayOfYearAndReverse(HebrewMonthNumbering numbering)
 {
     var calculator = new HebrewYearMonthDayCalculator(numbering);
     for (int year = 5400; year < 5419; year++)
     {
         int daysInYear = calculator.GetDaysInYear(year);
         for (int dayOfYear = 1; dayOfYear <= daysInYear; dayOfYear++)
         {
             YearMonthDay ymd = calculator.GetYearMonthDay(year, dayOfYear);
             Assert.AreEqual(dayOfYear, calculator.GetDayOfYear(ymd));
         }
     }
 }