예제 #1
0
        /// <summary>
        /// This test method returns the average
        /// accepts double value as a parameter
        /// </summary>
        public void TestAverage()
        {
            //Assemble
            List <double> hrt = new List <double>()
            {
                122.33, 91.55, 94.11
            };
            double expectedResult = 102.66;

            //Act
            double actualResult = Summary.Average(hrt);

            //Assert
            Assert.AreEqual(expectedResult, Math.Round(actualResult, 2, MidpointRounding.AwayFromZero));
        }