public void Image_Method() { Assert.Throws<ArgumentNullException>(() => new PinterestPinItButtonWidget().Image(null)); Assert.Throws<ArgumentException>(() => new PinterestPinItButtonWidget().Image(string.Empty)); var widget = new PinterestPinItButtonWidget(); Assert.Null(widget.Image()); Assert.True(ReferenceEquals(widget.Image("image"), widget)); Assert.Equal("image", widget.Image()); }
public void Image_Method() { Assert.Throws <ArgumentNullException>(() => new PinterestPinItButtonWidget().Image(null)); Assert.Throws <ArgumentException>(() => new PinterestPinItButtonWidget().Image(string.Empty)); var widget = new PinterestPinItButtonWidget(); Assert.Null(widget.Image()); Assert.True(ReferenceEquals(widget.Image("image"), widget)); Assert.Equal("image", widget.Image()); }
public void Constructors() { var widget = new PinterestPinItButtonWidget(); Assert.Equal("gray", widget.Color()); Assert.Equal(PinterestPinItButtonPinCountPosition.None, widget.Counter()); Assert.Null(widget.Description()); Assert.Null(widget.Image()); Assert.Equal("en", widget.Language()); Assert.Equal(PinterestPinItButtonShape.Rectangular, widget.Shape()); Assert.Equal(PinterestPinItButtonSize.Small, widget.Size()); Assert.Null(widget.Url()); }