public void TestHighestGrade() { Grades.GradeBook g = new Grades.GradeBook(); g.AddGrade(91); g.AddGrade(84.5f); Assert.AreEqual(g.ComputeStatistics().Highest, 91f); }
public void TestLowesttGrade() { Grades.GradeBook g = new Grades.GradeBook(); g.AddGrade(91); g.AddGrade(84.5f); GradeBookStatistics s = g.ComputeStatistics(); Assert.AreEqual(s.Lowest, 84.5f, 0.00001); }
public void computesHighestGrade() { Grades.GradeBook book = new Grades.GradeBook(); book.AddGrade(78); book.AddGrade(99); book.AddGrade(1); Grades.Statistics result = book.ComputeStatistics(); Assert.AreEqual(99, result.GetHighestGrade()); }
public void computeLetterGrade() { Grades.GradeBook book = new Grades.GradeBook(); book.AddGrade(78); book.AddGrade(99); book.AddGrade(1); Grades.Statistics result = book.ComputeStatistics(); Assert.AreEqual("F", result.LetterGrade); }
public void computeAverageGrade() { Grades.GradeBook book = new Grades.GradeBook(); book.AddGrade(78); book.AddGrade(99); book.AddGrade(1); Grades.Statistics result = book.ComputeStatistics(); Assert.AreEqual(59.33, result.GetAverGrade(), 0.01); }
public void TestAveragetGrade() { Grades.GradeBook g = new Grades.GradeBook(); g.AddGrade(91); g.AddGrade(89.5f); g.AddGrade(75); GradeBookStatistics s = g.ComputeStatistics(); Assert.AreEqual(s.Average, 85.166666666667f, 0.01); }