public void Height_Method() { Assert.Throws <ArgumentNullException>(() => ISurfingbirdSurfButtonWidgetExtensions.Height(null, 1)); new SurfingbirdSurfButtonWidget().Do(widget => { Assert.True(ReferenceEquals(widget.Height(1), widget)); Assert.Equal("1", widget.Height()); }); }
public void Color_Method() { Assert.Throws <ArgumentNullException>(() => ISurfingbirdSurfButtonWidgetExtensions.Color(null, SurfingbirdSurfButtonColor.Blue)); new SurfingbirdSurfButtonWidget().Do(widget => { Assert.True(ReferenceEquals(widget.Color(SurfingbirdSurfButtonColor.Blue), widget)); Assert.Equal("blue", widget.Color()); }); new SurfingbirdSurfButtonWidget().Do(widget => Assert.Equal("gray", widget.Color(SurfingbirdSurfButtonColor.Gray).Color())); new SurfingbirdSurfButtonWidget().Do(widget => Assert.Equal("green", widget.Color(SurfingbirdSurfButtonColor.Green).Color())); }
public void Layout_Method() { Assert.Throws <ArgumentNullException>(() => ISurfingbirdSurfButtonWidgetExtensions.Layout(null, SurfingbirdSurfButtonLayout.Common)); new SurfingbirdSurfButtonWidget().Do(widget => { Assert.True(ReferenceEquals(widget.Layout(SurfingbirdSurfButtonLayout.Common), widget)); Assert.Equal("common", widget.Layout()); }); new SurfingbirdSurfButtonWidget().Do(widget => Assert.Equal("micro", widget.Layout(SurfingbirdSurfButtonLayout.Micro).Layout())); new SurfingbirdSurfButtonWidget().Do(widget => Assert.Equal("vert", widget.Layout(SurfingbirdSurfButtonLayout.Vertical).Layout())); }