public static RenderDocumentDirective GetRenderDirective(string token, string hint, params APLComponent[] components) { APLDocument document = new APLDocument(); AlexaFooter.ImportInto(document); document.MainTemplate = new Layout(new AlexaFooter(hint)).AsMain(); document.MainTemplate.Items = new List <APLComponent>(); for (int i = 0; i < components.Length; i++) { document.MainTemplate.Items.Add(components[i]); } RenderDocumentDirective renderDirective = new RenderDocumentDirective { Token = token, Document = document }; return(renderDirective); }
public void AlexaFooterGeneratesCorrectJson() { var footer = new AlexaFooter("Hint Text"); Assert.True(Utility.CompareJson(footer, "AlexaFooter.json")); }