public void TestSquareRoot() { Assert.AreEqual(6.7, CodingQuiz_MathFunctions.SquareRoot(45), 2); // the 1 after (100) signifies 1 number only 2 signifies 2 i.e 6.7 }
public void TestSumDouble() { double x = CodingQuiz_MathFunctions.Sum(10.5, 10.5); Assert.AreEqual(x, 21); }
public void TestSumDecimal() { decimal x = CodingQuiz_MathFunctions.Sum(10.5M, 10.5M); Assert.AreEqual(x, 21); }
public void TestSumInt() { int x = CodingQuiz_MathFunctions.Sum(2, 2); Assert.AreEqual(x, 4); }