Exemple #1
0
 public void Calculate(double argument)
 {
     var calculator = new Sqrt();
     var testResult = calculator.Calculate(argument);
     var result = Math.Sqrt(argument);
     Assert.AreEqual(testResult,result);
 }
Exemple #2
0
        public void CalculateTest(double firstValue, double expected)
        {
            var    calculator = new Calculator.OneArgument.Sqrt();
            double result     = calculator.Calculator(firstValue);

            Assert.AreEqual(expected, result);
        }
Exemple #3
0
 public void SqrtTestsNegative()
 {
     var calculator = new Sqrt();
     var result = calculator.Calculate(-3);
 }
Exemple #4
0
 public void CalculateTest(double argument, double result, double accracy)
 {
     var testingFunction = new Sqrt();
     var testResult = testingFunction.Calculate(argument);
     Assert.AreEqual(result, testResult, accracy);
 }