/// <summary> /// Creates a page using a specific template. All other settings will have the default value. /// Will not work unless the test is already on the Add Page form. /// </summary> /// <param name="pageName">The name of the page.</param> /// <param name="template">The name of the template.</param> public void AddPageSelectTemplate(string pageName, string template) { PageNameField.Value = pageName; if (TemplateFolderSelectList.Option("Templates/").Exists) { TemplateFolderSelectList.Select("Templates/"); } else { TemplateFolderSelectList.Select("Root"); } PageTemplateSelect.Select(template); AddPageLink.ClickNoWait(); System.Threading.Thread.Sleep(1000); }
/// <summary> /// Creates a page using a specific template and gives All Users view permissions for the page. All other settings will have the default value. /// Will not work unless the test is already on the Add Page form. /// </summary> /// <param name="pageName">The name of the page.</param> /// <param name="template">The name of the template.</param> public void AddPageSelectTemplateAllUsersView(string pageName, string template) { PageNameField.Value = pageName; if (TemplateFolderSelectList.Option("Templates/").Exists) { TemplateFolderSelectList.Select("Templates/"); } else { TemplateFolderSelectList.Select("Root"); } PageTemplateSelect.Select(template); SetPermissionForRole("Grant", "View", "All Users"); AddPageLink.ClickNoWait(); System.Threading.Thread.Sleep(1500); }