public void ShouldCalculateCorectAreaFor(double lenght, double width, double expectedArea) { var shape = new NewAndSmartRectangle(lenght, width); var actualArea = ShapeAreaManager.CalculateArea(shape); Assert.AreEqual(expectedArea, actualArea); }
public void ShouldHaveInvalidPostconditionsFor(double lenght, double width) { Assert.Throws <InvalidOperationException>(() => { var shape = new NewAndSmartRectangle(lenght, width); ShapeAreaManager.CalculateArea(shape); }); }