コード例 #1
0
        public void Is_Given_An_Item_Of_Type_blockquote_Then_Is_Valid_Returns_True(BlockQuoteControlFactory factory)
        {
            var control = BuildControl();

            var actual = factory.IsValid(control);

            actual.Should().BeTrue();
        }
コード例 #2
0
        public void Is_Given_An_Item_Of_Type_blockquote_Then_Is_Valid_Returns_False(BlockQuoteControlFactory factory)
        {
            var control = new ItemBuilder().SetType("paragraph")
                          .SetValue("To become an apprentice, you must: ")
                          .SetTableValue(new List <string>())
                          .Build();

            var actual = factory.IsValid(control);

            actual.Should().BeFalse();
        }
コード例 #3
0
        public void Is_Given_An_Item_Of_Type_blockquote_Then_Create_Returns_BlockQuote(BlockQuoteControlFactory factory)
        {
            var control = BuildControl();

            var actual = factory.Create(control) as BlockQuote;

            actual.Should().NotBeNull();
            actual.Content.Any().Should().BeTrue();
        }