示例#1
0
文件: CalcTests.cs 项目: K1516/DEMO8
        public void AddTest()
        {
            Calc calc = new Calc();
            int number1 = 5;
            int number2 = 7;
            int expected = 12;

            //act
            int actual = calc.Add(number1, number2);

            //assert
            Assert.AreEqual(expected, actual);
        }
示例#2
0
文件: CalcTests.cs 项目: K1516/DEMO8
        public void MultipleTest()
        {
            Calc calc = new Calc();
            int number1 = 5;
            int number2 = 7;
            int expected = 35;

            //act
            int actual = calc.Multiple(number1, number2);

            //assert
            Assert.AreEqual(expected, actual);

        }