public void GcdSteinsAlgorithmTests_ArgumentException(int expected, params int[] numbers) { // Arrange double executionTime; // Act // Assert Assert.ThrowsException <ArgumentException>(() => EuclidsAlgorithmRefactoring.GcdEuclidsAlgorithm(out executionTime, numbers)); }
public void GcdEuclidsAlgorithmTests(int expected, params int[] numbers) { // Arrange double executionTime; // Act int gcd = EuclidsAlgorithmRefactoring.GcdEuclidsAlgorithm(out executionTime, numbers); // Assert Assert.AreEqual(expected, gcd); Assert.IsTrue(executionTime < 100); }