private void ParametrizeLayouter(int centerPointX, int centerPointY, IEnumerable <Size> rectanglesLis, int rectanglesCount = 200, int minRectangleSizeWidth = 50, int minRectangleSizeHeight = 25, int maxRectangleSizeWidth = 300, int maxRectangleSizeHeight = 90) { cloudCenterX = centerPointX; cloudCenterY = centerPointY; layouter = new CircularCloudLayouter(new Point(cloudCenterX, cloudCenterY)); sizedRects = rectanglesLis ?? GenerateRectangleSizes(rectanglesCount, minRectangleSizeWidth, minRectangleSizeHeight, maxRectangleSizeWidth, maxRectangleSizeHeight); }
public void CloudLayoutShouldFail_WithEmptyRect() { withTearDown = false; layouter = new CircularCloudLayouter(new Point(cloudCenterX, cloudCenterY)); Action act = () => layouter.PutNextRectangle(new Size()); act.ShouldThrow <ArgumentException>(); }