コード例 #1
0
        public void Test_Reciprocal_1()
        {
            Logic.Calculator Calc = new Logic.Calculator();
            Calc.Number_entered(2);
            Calc.Reciprocal_entered();
            Calc.Reciprocal_entered();
            Calc.Reciprocal_entered();
            string result = Calc.Reciprocal_entered();

            Assert.AreEqual("2", result);
        }
コード例 #2
0
 public void Test_Reciprocal_Calc()
 {
     Logic.Calculator calculator = new Logic.Calculator();
     calculator.Number_entered(-4.0);
     calculator.Reciprocal_entered();
     Assert.AreEqual("-0.25", calculator.Equals());
 }