using ConsoleApp1; using System.Security.Cryptography.X509Certificates; namespace Test { [TestClass] public class UnitTest1 { [TestMethod] public void Sum_AreEqual() { double x = 4; double y = 6; double except = 10; double actual = Calculate.Sum(x, y); Assert.AreEqual(except, actual); } [TestMethod] public void Sum_AreNotEqual() { double x = 4; double y = -6; double except = 10; double actual = Calculate.Sum(x, y); Assert.AreNotEqual(except, actual); } [TestMethod] public void Subtraction_AreEqual() { double x = 4; double y = 6; double except = -2; double actual = Calculate.Subtraction(x, y); Assert.AreEqual(except, actual); } [TestMethod] public void Subtraction_AreNotEqual() { double x = 4; double y = 6; double except = 2; double actual = Calculate.Subtraction(x, y); Assert.AreNotEqual(except, actual); } [TestMethod] public void Multiplication_AreEqual() { double x = -1; double y = -3; double except = 3; double actual = Calculate.Multiplication(x, y); Assert.AreEqual(except, actual); } [TestMethod] public void Multiplication_AreNotEqual() { double x = 0; double y = 6; double except = 6; double actual = Calculate.Multiplication(x, y); Assert.AreNotEqual(except, actual); } [TestMethod] public void Division_AreEqual() { double x = 0; double y = 5; double except = 0; double actual = Calculate.Division(x, y); Assert.AreEqual(except, actual); } [TestMethod] public void Division_AreNotEqual() { double x = -100; double y = 10; double except = 10; double actual = Calculate.Division(x, y); Assert.AreNotEqual(except, actual); } [TestMethod] public void Exponentiation_AreEqual() { double x = 2; double y = 0; double except = 1; double actual = Calculate.Exponentiation(x, y); Assert.AreEqual(except, actual); } [TestMethod] public void Exponentiation_AreNotEqual() { double x = 5; double y = 2; double except = 26; double actual = Calculate.Exponentiation(x, y); Assert.AreNotEqual(except, actual); } } }