BlockField() public method

public BlockField ( string fieldName, Action options ) : IDocumentBuilder
fieldName string
options Action
return IDocumentBuilder
        public void PropertiesAppliedToBlockFieldShouldPersistAfterSettingContent()
        {
            using (var expected = new DocxDocument(Resources.WithStyledSdtElementsContentInserted))
            using (var document = new DocxDocument(Resources.WithStyledSdtElements))
            {
                var builder = new DocxDocumentBuilder(document);

                builder.BlockField("BlockField", x => x.Paragraph("Первый").Paragraph("Второй"));

                Assert.IsTrue(new DocxDocumentEqualityComparer().Equals(expected, document));
            }
        }
        public void CanSetContentToBlockFieldConsistingOfTwoParagraphs()
        {
            using (var expected = new DocxDocument(Resources.WithTwoParagraphsInBlockField))
            using (var document = new DocxDocument(Resources.WithSdtElements))
            {
                var builder = new DocxDocumentBuilder(document);

                builder.BlockField("BlockField", x => x.Paragraph("Первый").Paragraph("Второй"));

                Assert.IsTrue(new DocxDocumentEqualityComparer().Equals(expected, document));
            }
        }