public void Format_ContentIsFeatureNode_UsesHtmlFeatureFormatterWithCorrectArgument() { var fakeHtmlFeatureFormatter = new Mock<IHtmlFeatureFormatter>(); var formatter = new HtmlContentFormatter(fakeHtmlFeatureFormatter.Object, new HtmlIndexFormatter()); var featureNode = new FeatureNode( FileSystem.FileInfo.FromFileName(@"c:\temp\test.feature"), ".", new Feature()); formatter.Format(featureNode, new INode[0]); fakeHtmlFeatureFormatter.Verify(f => f.Format(featureNode.Feature)); }
public HtmlDocumentFormatter( IConfiguration configuration, HtmlHeaderFormatter htmlHeaderFormatter, HtmlTableOfContentsFormatter htmlTableOfContentsFormatter, HtmlContentFormatter htmlContentFormatter, HtmlFooterFormatter htmlFooterFormatter, HtmlResourceSet htmlResources, IFileSystem fileSystem) { this.configuration = configuration; this.htmlHeaderFormatter = htmlHeaderFormatter; this.htmlTableOfContentsFormatter = htmlTableOfContentsFormatter; this.htmlContentFormatter = htmlContentFormatter; this.htmlFooterFormatter = htmlFooterFormatter; this.htmlResources = htmlResources; this.fileSystem = fileSystem; }