public void CallErrorWhereTriangleIsNotTriangleTest(params double[] sides) { Exception exception = Assert.Throws <Exception>(() => TriangleTypeChecker.CheckTriangleType(sides)); Assert.Equal("The triangle does not exist", exception.Message); }
public void CallArrayNegativeNumberErrorTest(params double[] sides) { var exception = Assert.Throws <ArgumentException>(() => TriangleTypeChecker.CheckTriangleType(sides)); Assert.Equal("Parties cannot be negative", exception.Message); }
public void SquarenessTest(params double[] sides) { Assert.Equal((TriangleTypeChecker.TriangleType) 2, TriangleTypeChecker.CheckTriangleType(sides)); }
public void CallArrayLengthErrorTest(params double[] sides) { var exception = Assert.Throws <ArgumentException>(() => TriangleTypeChecker.CheckTriangleType(sides)); Assert.Equal("The number of sides is not 3", exception.Message); }
public void AcuteAngledTest(params double[] sides) { Assert.Equal((TriangleTypeChecker.TriangleType) 0, TriangleTypeChecker.CheckTriangleType(sides)); }