public void Constructors()
 {
   var widget = new VkontaktePollWidget();
   Assert.Null(widget.ElementId());
   Assert.Null(widget.Id());
   Assert.Null(widget.Url());
   Assert.Null(widget.Width());
 }
예제 #2
0
        public void Constructors()
        {
            var widget = new VkontaktePollWidget();

            Assert.Null(widget.ElementId());
            Assert.Null(widget.Id());
            Assert.Null(widget.Url());
            Assert.Null(widget.Width());
        }
    public void Width_Method()
    {
      Assert.Throws<ArgumentNullException>(() => new VkontaktePollWidget().Width(null));
      Assert.Throws<ArgumentException>(() => new VkontaktePollWidget().Width(string.Empty));

      var widget = new VkontaktePollWidget();
      Assert.Null(widget.Width());
      Assert.True(ReferenceEquals(widget.Width("width"), widget));
      Assert.Equal("width", widget.Width());
    }
    public void ElementId_Method()
    {
      Assert.Throws<ArgumentNullException>(() => new VkontaktePollWidget().ElementId(null));
      Assert.Throws<ArgumentException>(() => new VkontaktePollWidget().ElementId(string.Empty));

      var widget = new VkontaktePollWidget();
      Assert.Null(widget.ElementId());
      Assert.True(ReferenceEquals(widget.ElementId("elementId"), widget));
      Assert.Equal("elementId", widget.ElementId());
    }
예제 #5
0
        public void Width_Method()
        {
            Assert.Throws <ArgumentNullException>(() => new VkontaktePollWidget().Width(null));
            Assert.Throws <ArgumentException>(() => new VkontaktePollWidget().Width(string.Empty));

            var widget = new VkontaktePollWidget();

            Assert.Null(widget.Width());
            Assert.True(ReferenceEquals(widget.Width("width"), widget));
            Assert.Equal("width", widget.Width());
        }
예제 #6
0
        public void ElementId_Method()
        {
            Assert.Throws <ArgumentNullException>(() => new VkontaktePollWidget().ElementId(null));
            Assert.Throws <ArgumentException>(() => new VkontaktePollWidget().ElementId(string.Empty));

            var widget = new VkontaktePollWidget();

            Assert.Null(widget.ElementId());
            Assert.True(ReferenceEquals(widget.ElementId("elementId"), widget));
            Assert.Equal("elementId", widget.ElementId());
        }