public void GapsFrequencyAnalyzer_FormulaForWindowExceededByMoreThan20Days(int windowExceededBy, double expectedResult, double errorMargin)
        {
            // Act
            var result = GapsFrequencyAnalyzer.FormulaForWindowExceededLessThan20Days(windowExceededBy);

            // Assert
            Assert.That(Math.Abs((double)result - expectedResult), Is.LessThanOrEqualTo(errorMargin));
        }
        public void GapsFrequencyAnalyzer_FormulaForWindowExceededByMoreThan20Days()
        {
            // Act
            var result = GapsFrequencyAnalyzer.FormulaForWindowExceededByMoreThan20Days();

            // Assert
            Assert.That(result, Is.EqualTo(Defaults.Scores.Zero));
        }
 public void Setup()
 {
     this.databaseRepository     = new Mock <IDatabaseRepository>();
     this.databaseGapsRepository = new Mock <IDatabaseGapsRepository>();
     this.logger = TestUtilities.GetMockLogger();
     this.gapsFrequencyAnalyzer = new GapsFrequencyAnalyzer(
         this.databaseRepository.Object,
         this.databaseGapsRepository.Object,
         this.logger.Object);
 }