public void FactoryMethodCreatesLawnWithWidthAndHeightMatchingSuppliedSizeString(string size, int expectedWidth, int expectedHeight) { var lawn = Lawn.CreateWith(size); Assert.That(lawn, Is.Not.Null); Assert.That(lawn.Width, Is.EqualTo(expectedWidth)); Assert.That(lawn.Height, Is.EqualTo(expectedHeight)); }
public void FactoryMethodThrowsArgumentExceptionIfSizeStringInvalid(string invalidSize) { Assert.Throws <ArgumentException>(() => Lawn.CreateWith(invalidSize)); }