public void CalculatorTest( double firstValue, double expected) { var calculator = new Log10(); var actualResult = calculator.Calculate(firstValue); Assert.Throws <Exception>(() => calculator.Calculate(-5)); Assert.AreEqual(expected, actualResult); }
public void Calculate() { Log10 calculator = new Log10(); double result = calculator.Calculate(1); Assert.AreEqual(0, result, 0.001); }
public void CalculateTest(double firstValue, double expected) { var calculator = new Log10(); var actualResult = calculator.Calculate(firstValue); Assert.AreEqual(expected, actualResult, 0.0001); }
public void CalculateReverseTestStrong(double firstValue, double expected) { IOneArgumentCalculator calculator = new Log10(); double result = calculator.Calculate(firstValue); Assert.AreEqual(expected, result); }
public void ExceptionTest() { var calculator = new Log10(); Assert.Throws <Exception>(() => calculator.Calculate(0)); }
public void ExceptionLessThanZeroTest(double firstArgument) { var calculator = new Log10(); Assert.Throws <Exception>(() => calculator.Calculate(firstArgument)); }