public void ExpandPagesAndSelectChildPageForSingleItemPage() { BAT.Macros().NavigateTo().Pages(this.Culture); BAT.Wrappers().Backend().Pages().PagesWrapper().OpenPageZoneEditor(PageName); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().EditWidget(WidgetName); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().SwitchToSingleItemSettingsTab(); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().SelectExistingPage(); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().ClickSelectButton(); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().VerifyPageStatusAndIcon(PageName, "Locked"); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().SelectItemsInHierarchicalSelector(SingleItemPage); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().VerifyPageStatusAndIcon(SingleItemPage, "Published"); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().DoneSelecting(); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().VerifySelectedItemsFromHierarchicalSelector(this.selectedItemsFromPageSelector); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().SaveChanges(); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().PublishPage(); }
public void VerifyGeneratedTemplatesDefaultResourcePackages() { RuntimeSettingsModificator.ExecuteWithClientTimeout(800000, () => BAT.Macros().NavigateTo().CustomPage("~/sitefinity/design/pagetemplates", false)); RuntimeSettingsModificator.ExecuteWithClientTimeout(800000, () => BAT.Macros().User().EnsureAdminLoggedIn()); BAT.Wrappers().Backend().PageTemplates().PageTemplateMainScreen().OpenTemplateEditor(BootstrapTemplate); Assert.IsTrue(BATFrontend.Wrappers().Backend().PageTemplates().PageTemplateEditor().IsPlaceHolderPresent(PlaceHolderId), "Placeholder not found in template editor"); BAT.Wrappers().Backend().PageTemplates().PageTemplateModifyScreen().ClickBackToTemplatesButton(); BAT.Wrappers().Backend().PageTemplates().PageTemplateMainScreen().OpenTemplateEditor(SemanticTemplate); Assert.IsTrue(BATFrontend.Wrappers().Backend().PageTemplates().PageTemplateEditor().IsPlaceHolderPresent(PlaceHolderId), "Placeholder not found in template editor"); BAT.Wrappers().Backend().PageTemplates().PageTemplateModifyScreen().ClickBackToTemplatesButton(); BAT.Wrappers().Backend().PageTemplates().PageTemplateMainScreen().OpenTemplateEditor(FoundationTemplate); Assert.IsTrue(BATFrontend.Wrappers().Backend().PageTemplates().PageTemplateEditor().IsPlaceHolderPresent(PlaceHolderId), "Placeholder not found in template editor"); BAT.Wrappers().Backend().PageTemplates().PageTemplateModifyScreen().ClickBackToTemplatesButton(); }
public void VerifyPagingWhenPagesAreMoreThanTen() { BAT.Macros().NavigateTo().Pages(this.Culture); BAT.Wrappers().Backend().Pages().PagesWrapper().OpenPageZoneEditor(PageName); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().EditWidget(WidgetName); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().SwitchToListSettingsTab(); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().VerifyCheckedRadioButtonOption(WidgetDesignerRadioButtonIds.UsePaging); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().ChangePagingOrLimitValue("1", "Paging"); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().SaveChanges(); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().PublishPage(); BAT.Macros().NavigateTo().CustomPage(PageName.ToLower(), true, this.Culture); BATFeather.Wrappers().Frontend().CommonWrapper().NavigateToNextSectionUsingPager(); Assert.IsTrue(ActiveBrowser.Url.EndsWith(PageName + "/11", StringComparison.OrdinalIgnoreCase)); Assert.IsTrue(BATFeather.Wrappers().Frontend().News().NewsWrapper().IsNewsTitlesPresentOnThePageFrontend(new string[] { NewsTitle1 })); }
public void AddLightNavigationAndMvcNavigationOnTheSamePage() { BAT.Macros().NavigateTo().Pages(this.Culture); BAT.Wrappers().Backend().Pages().PagesWrapper().OpenPageZoneEditor(PageName); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().AddWidgetToDropZone(WidgetName); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().AddMvcWidgetHybridModePage(WidgetName); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().PublishPage(); string[] pages = new string[] { PageName, Page1, Page2 }; BAT.Macros().NavigateTo().CustomPage("~/" + PageName.ToLower(), true, this.Culture); Assert.IsFalse(ActiveBrowser.ContainsText(ServerErrorMessage), ServerErrorMessage); BATFeather.Wrappers().Frontend().Navigation().NavigationWrapper().VerifyNavigationOnFrontend(MvcNavClass, pages); BAT.Wrappers().Frontend().Navigation().NavigationFrontendWrapper().VerifyPagesFrontEndNavigation(LightNavClass, pages); }
public void CssWidgetAndNewsWidgetOnTheSamePage() { BAT.Macros().NavigateTo().Pages(this.Culture); BAT.Wrappers().Backend().Pages().PagesWrapper().OpenPageZoneEditor(PageName); //// Switch the focus to the zone editor HtmlDiv radDockZone = ActiveBrowser.Find .ByExpression <HtmlDiv>("placeholderid=" + "Body") .AssertIsPresent <HtmlDiv>("Body"); radDockZone.MouseClick(); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().EditWidget(WidgetName); BATFeather.Wrappers().Backend().ScriptAndStyles().CssWidgetEditWrapper().FillCodeInEditableArea(CssValueExpected); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().SaveChanges(); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().PublishPage(); this.VerifyPageOnTheFrontend(); }
/// <summary> /// Verifies the social share template content on the frontend. /// </summary> /// <param name="socialShareContent">Content of the social share.</param> /// <returns></returns> public bool IsSocialShareTemplateContentPresentOnTheFrontend(string[] socialShareContent) { HtmlDiv frontendPageMainDiv = BAT.Wrappers().Frontend().Pages().PagesWrapperFrontend().GetPageContent(); bool isContained = false; for (int i = 0; i < socialShareContent.Length; i++) { isContained = frontendPageMainDiv.InnerText.Contains(socialShareContent[i]); if (!isContained) { return(isContained); } } return(isContained); }
public void ContentBlockWidgetOnPageBasedOnBootstrapTemplate() { RuntimeSettingsModificator.ExecuteWithClientTimeout(800000, () => BAT.Macros().NavigateTo().CustomPage("~/sitefinity/pages", false, this.Culture)); RuntimeSettingsModificator.ExecuteWithClientTimeout(800000, () => BAT.Macros().User().EnsureAdminLoggedIn()); BAT.Arrange(this.ArrangementClass).AddParameter("templateName", BootstrapTemplate).ExecuteSetUp(); BAT.Macros().NavigateTo().Pages(this.Culture); BAT.Wrappers().Backend().Pages().PagesWrapper().OpenPageZoneEditor(PageName); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().AddWidgetToPlaceHolderPureMvcMode(WidgetName); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().EditWidget(WidgetName); BATFeather.Wrappers().Backend().ContentBlocks().ContentBlocksWrapper().FillContentToContentBlockWidget(ContentBlockContent); BATFeather.Wrappers().Backend().ContentBlocks().ContentBlocksWrapper().SaveChanges(); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().PublishPage(); BAT.Macros().NavigateTo().CustomPage("~/" + PageName.ToLower(), false, this.Culture); BATFeather.Wrappers().Frontend().ContentBlock().ContentBlockWrapper().VerifyContentOfContentBlockOnThePageFrontend(ContentBlockContent); }
public void VerifyGeneratedTemplatesDefaultResourcePackages() { BAT.Macros().User().EnsureAdminLoggedIn(); BAT.Macros().NavigateTo().Design().PageTemplates(); BAT.Wrappers().Backend().PageTemplates().PageTemplateMainScreen().OpenTemplateEditor(BootstrapTemplate); Assert.IsTrue(BATFrontend.Wrappers().Backend().PageTemplates().PageTemplateEditor().IsPlaceHolderPresent(PlaceHolderId), "Placeholder not found in template editor"); BAT.Wrappers().Backend().PageTemplates().PageTemplateModifyScreen().ClickBackToTemplatesButton(); BAT.Wrappers().Backend().PageTemplates().PageTemplateMainScreen().OpenTemplateEditor(SemanticTemplate); Assert.IsTrue(BATFrontend.Wrappers().Backend().PageTemplates().PageTemplateEditor().IsPlaceHolderPresent(PlaceHolderId), "Placeholder not found in template editor"); BAT.Wrappers().Backend().PageTemplates().PageTemplateModifyScreen().ClickBackToTemplatesButton(); BAT.Wrappers().Backend().PageTemplates().PageTemplateMainScreen().OpenTemplateEditor(FoundationTemplate); Assert.IsTrue(BATFrontend.Wrappers().Backend().PageTemplates().PageTemplateEditor().IsPlaceHolderPresent(PlaceHolderId), "Placeholder not found in template editor"); BAT.Wrappers().Backend().PageTemplates().PageTemplateModifyScreen().ClickBackToTemplatesButton(); }
public void NavigateDetailTemplateOfNewsOnPageBasedOnSemanticUITemplate() { this.pageTemplateName = "SemanticUI.default"; BAT.Macros().User().EnsureAdminLoggedIn(); BAT.Arrange(this.ArrangementClass).AddParameter("templateName", this.pageTemplateName).ExecuteSetUp(); BAT.Macros().NavigateTo().Pages(this.Culture); BAT.Wrappers().Backend().Pages().PagesWrapper().OpenPageZoneEditor(PageName); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().AddWidgetToPlaceHolderPureMvcMode(WidgetName); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().CheckWidgetContent(WidgetName, NewsTitle); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().PublishPage(); this.VerifyNewsOnTheFrontend(); BATFeather.Wrappers().Frontend().News().NewsWrapper().ClickNewsTitle(NewsTitle); Assert.IsTrue(BATFeather.Wrappers().Frontend().News().NewsWrapper().IsNewsTitlePresentOnDetailMasterPage(NewsTitle)); }
/// <summary> /// Verifies the categories titles on the frontend page. /// </summary> /// <param name="categoriesTitles">The categories titles.</param> /// <returns>true or false depending on categories titles presence on frontend</returns> public bool IsCategoriesTitlesPresentOnTheFrontendPage(string[] categoriesTitles) { ActiveBrowser.WaitForElementWithCssClass("sfPublicWrapper"); HtmlDiv frontendPageMainDiv = BAT.Wrappers().Frontend().Pages().PagesWrapperFrontend().GetPageContent(); for (int i = 0; i < categoriesTitles.Length; i++) { HtmlAnchor categoriesAnchor = frontendPageMainDiv.Find.ByExpression <HtmlAnchor>("tagname=a", "InnerText=" + categoriesTitles[i]); if (categoriesAnchor == null || !categoriesAnchor.IsVisible()) { return(false); } } return(true); }
public void CheckSelectorsAfterSelectUnselectAndUNPublishingDynamicItem() { RuntimeSettingsModificator.ExecuteWithClientTimeout(800000, () => BAT.Macros().NavigateTo().CustomPage("~/sitefinity/pages", false)); RuntimeSettingsModificator.ExecuteWithClientTimeout(800000, () => BAT.Macros().User().EnsureAdminLoggedIn()); BAT.Macros().NavigateTo().Pages(this.Culture); BAT.Wrappers().Backend().Pages().PagesWrapper().OpenPageZoneEditor(PageName); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().EditWidget(WidgetName); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().SelectWhichItemsToDisplay(WhichNewsToDisplay); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().ClickSelectButton(); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().WaitForItemsToAppear(20); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().SelectItemsInFlatSelector(this.selectedItemsNames); var countOfSelectedItems = this.selectedItemsNames.Count(); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().CheckNotificationInSelectedTab(countOfSelectedItems); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().DoneSelecting(); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().VerifySelectedItemsFromFlatSelector(this.selectedItemsNames); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().SaveChanges(); foreach (var dynamicItem in this.selectedItemsNames) { BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().CheckWidgetContent(WidgetName, dynamicItem); } BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().PublishPage(); this.UnpublishDynamicItem(); BAT.Wrappers().Backend().Pages().PagesWrapper().OpenPageZoneEditor(PageName); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().EditWidget(WidgetName); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().VerifySelectedItemsFromFlatSelector(this.selectedItemsNames); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().ClickSelectButton(); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().OpenAllTab(); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().WaitForItemsToAppear(20); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().SelectItemsInFlatSelector(SelectedItemsName6); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().CheckNotificationInSelectedTab(countOfSelectedItems - 1); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().DoneSelecting(); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().SaveChanges(); foreach (var dynamicTitle in this.finalItemsNames) { BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().CheckWidgetContent(WidgetName, dynamicTitle); } BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().PublishPage(); BAT.Macros().NavigateTo().CustomPage("~/" + PageName.ToLower(), true, this.Culture); Assert.IsTrue(BATFeather.Wrappers().Frontend().ModuleBuilder().ModuleBuilderWrapper().VerifyDynamicContentPresentOnTheFrontend(this.finalItemsNames)); }
public void CheckAllOptionsInSocialShareWidget() { BAT.Macros().NavigateTo().Pages(this.Culture); BAT.Wrappers().Backend().Pages().PagesWrapper().OpenPageZoneEditor(PageName); BATFeather.Wrappers().Backend().SocialShare().SocialSharePageEditorWrapper().VerifySocialShareOptionsPresentOnBackend(4, SocialShareOptions.Facebook, SocialShareOptions.Tweeter, SocialShareOptions.GooglePlus, SocialShareOptions.LinkedIn); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().EditWidget(WidgetName); BATFeather.Wrappers().Backend().SocialShare().SocialShareWidgetEditWrapper().SelectUnselectAllSocialShareOptions(false); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().SaveChanges(); BATFeather.Wrappers().Backend().SocialShare().SocialSharePageEditorWrapper().VerifySocialShareOptionsNotPresentInBackend(SocialShareOptions.Facebook, SocialShareOptions.Tweeter, SocialShareOptions.GooglePlus, SocialShareOptions.LinkedIn); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().EditWidget(WidgetName); BATFeather.Wrappers().Backend().SocialShare().SocialShareWidgetEditWrapper().SelectUnselectAllSocialShareOptions(); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().SaveChanges(); BATFeather.Wrappers().Backend().SocialShare().SocialSharePageEditorWrapper().VerifySocialShareOptionsPresentOnBackend( 13, SocialShareOptions.Facebook, SocialShareOptions.Tweeter, SocialShareOptions.GooglePlus, SocialShareOptions.GoogleBookmarks, SocialShareOptions.Digg, SocialShareOptions.Blogger, SocialShareOptions.Tumblr, SocialShareOptions.LinkedIn, SocialShareOptions.Delicious, SocialShareOptions.MySpace, SocialShareOptions.StumbleUpon, SocialShareOptions.Reddit, SocialShareOptions.MailTo); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().PublishPage(); BAT.Macros().NavigateTo().CustomPage("~/" + PageName.ToLower(), true, this.Culture); BATFeather.Wrappers().Frontend().SocialShare().SocialShareWrapper().VerifySocialShareOptionsOnFrontend( 13, SocialShareOptions.Facebook, SocialShareOptions.Tweeter, SocialShareOptions.GooglePlus, SocialShareOptions.GoogleBookmarks, SocialShareOptions.Digg, SocialShareOptions.Blogger, SocialShareOptions.Tumblr, SocialShareOptions.LinkedIn, SocialShareOptions.Delicious, SocialShareOptions.MySpace, SocialShareOptions.StumbleUpon, SocialShareOptions.Reddit, SocialShareOptions.MailTo); }
public void VerifyNoLimitAndPaginationListSettingsOnFrontendPageForSearchResultsWidget() { RuntimeSettingsModificator.ExecuteWithClientTimeout(800000, () => BAT.Macros().NavigateTo().CustomPage("~/sitefinity/pages", true, null, new HtmlFindExpression("class=~sfMain"))); BAT.Macros().NavigateTo().Pages(this.Culture); BAT.Wrappers().Backend().Pages().PagesWrapper().OpenPageZoneEditor(SearchPage); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().AddMvcWidgetHybridModePage(SearchBoxWidget); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().EditWidget(SearchBoxWidget); BATFeather.Wrappers().Backend().Search().SearchBoxWrapper().SelectSearchIndex(SearchIndexName); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().ClickSelectButton(); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().WaitForItemsToAppear(3); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().SelectItemsInFlatSelector(ResultsPage); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().DoneSelecting(); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().VerifySelectedItemsFromFlatSelector(new string[] { ResultsPage }); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().SaveChanges(); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().PublishPage(); BAT.Wrappers().Backend().Pages().PagesWrapper().OpenPageZoneEditor(ResultsPage); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().AddMvcWidgetHybridModePage(SearchResultsWidget); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().EditWidget(SearchResultsWidget); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().VerifyPageValue("20", "Paging"); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().VerifyPageValue("20", "Limit"); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().ChangePagingOrLimitValue("2", "Paging"); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().VerifyPageValue("2", "Paging"); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().VerifyPageValue("20", "Limit"); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().SaveChanges(); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().EditWidget(SearchResultsWidget); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().VerifyPageValue("2", "Paging"); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().VerifyPageValue("20", "Limit"); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().SelectRadioButtonOption(WidgetDesignerRadioButtonIds.AllItems); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().VerifyCheckedRadioButtonOption(WidgetDesignerRadioButtonIds.AllItems); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().SaveChanges(); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().EditWidget(SearchResultsWidget); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().VerifyCheckedRadioButtonOption(WidgetDesignerRadioButtonIds.AllItems); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().VerifyPageValue("2", "Paging"); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().VerifyPageValue("20", "Limit"); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().PressCancelButton(); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().PublishPage(); BAT.Macros().NavigateTo().CustomPage("~/" + SearchPage.ToLower(), true, this.Culture); BATFeather.Wrappers().Frontend().Search().SearchWrapper().EnterSearchText(SearchText); BATFeather.Wrappers().Frontend().Search().SearchWrapper().ClickSearchButton(ResultsPage.ToLower()); BATFeather.Wrappers().Frontend().Search().SearchWrapper().VerifySearchResultsLabel(5, SearchText); BATFeather.Wrappers().Frontend().Search().SearchWrapper().VerifySearchResultsList(NewsTitle5, NewsTitle4, NewsTitle3, NewsTitle2, NewsTitle1); BAT.Macros().NavigateTo().Pages(this.Culture); }
public void LinkSelectorInsertAnAnchor() { BAT.Macros().NavigateTo().Pages(this.Culture); BAT.Wrappers().Backend().Pages().PagesWrapper().OpenPageZoneEditor(PageName); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().EditWidget(WidgetName); BATFeather.Wrappers().Backend().ContentBlocks().ContentBlocksWrapper().OpenLinkSelector(); BATFeather.Wrappers().Backend().ContentBlocks().LinkSelectorWrapper().SwitchToSelectedTab(SelectedTabName); Assert.IsFalse(BATFeather.Wrappers().Backend().ContentBlocks().LinkSelectorWrapper().IsInsertLinkButtonEnabled()); BATFeather.Wrappers().Backend().ContentBlocks().LinkSelectorWrapper().VerifySelectedValueInAnchorDropdown(DefaultAnchorDropdownValue); BATFeather.Wrappers().Backend().ContentBlocks().LinkSelectorWrapper().VerifyThatHowToInsertAnAnchorLinkIsVisible(); BATFeather.Wrappers().Backend().ContentBlocks().LinkSelectorWrapper().EnterTextToDisplay(TextToDisplay, TabIndex); Assert.IsFalse(BATFeather.Wrappers().Backend().ContentBlocks().LinkSelectorWrapper().IsInsertLinkButtonEnabled()); BATFeather.Wrappers().Backend().ContentBlocks().LinkSelectorWrapper().SelectAnchor(AnchorName); BATFeather.Wrappers().Backend().ContentBlocks().LinkSelectorWrapper().InsertLink(); BATFeather.Wrappers().Backend().ContentBlocks().ContentBlocksWrapper().VerifyContentBlockTextDesignMode("Test1" + "Test2" + TextToDisplay); BATFeather.Wrappers().Backend().ContentBlocks().ContentBlocksWrapper().SelectLinkInEditableArea(TextToDisplay); BATFeather.Wrappers().Backend().ContentBlocks().ContentBlocksWrapper().OpenLinkSelector(); BATFeather.Wrappers().Backend().ContentBlocks().LinkSelectorWrapper().VerifySelectedValueInAnchorDropdown(AnchorName); BATFeather.Wrappers().Backend().ContentBlocks().LinkSelectorWrapper().VerifyCorrectTextToDisplay(TextToDisplay, TabIndex); BATFeather.Wrappers().Backend().ContentBlocks().LinkSelectorWrapper().CancelEditingLinkSelector(); BATFeather.Wrappers().Backend().ContentBlocks().ContentBlocksWrapper().ClickHtmlButton(); BATFeather.Wrappers().Backend().ContentBlocks().ContentBlocksWrapper().VerifyContentInHtmlEditableArea(HtmlContent); BATFeather.Wrappers().Backend().ContentBlocks().ContentBlocksWrapper().SaveChanges(); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().VerifyCreatedLink(TextToDisplay, Anchor); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().PublishPage(); BAT.Macros().NavigateTo().CustomPage("~/" + PageName.ToLower(), true, this.Culture); BATFeather.Wrappers().Frontend().ContentBlock().ContentBlockWrapper().VerifyCreatedLink(TextToDisplay, Anchor); BAT.Macros().NavigateTo().Pages(this.Culture); BAT.Wrappers().Backend().Pages().PagesWrapper().OpenPageZoneEditor(PageName); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().EditWidget(WidgetName); BATFeather.Wrappers().Backend().ContentBlocks().ContentBlocksWrapper().DeleteAllContentInEditableArea(); BATFeather.Wrappers().Backend().ContentBlocks().ContentBlocksWrapper().OpenLinkSelector(); BATFeather.Wrappers().Backend().ContentBlocks().LinkSelectorWrapper().SwitchToSelectedTab(SelectedTabName); Assert.IsFalse(BATFeather.Wrappers().Backend().ContentBlocks().LinkSelectorWrapper().IsInsertLinkButtonEnabled()); BATFeather.Wrappers().Backend().ContentBlocks().LinkSelectorWrapper().VerifyAnchorDropdownIsNotVisible(); BATFeather.Wrappers().Backend().ContentBlocks().LinkSelectorWrapper().VerifyTextToDisplayIsNotVisible(TabIndex); BATFeather.Wrappers().Backend().ContentBlocks().LinkSelectorWrapper().VerifyNoAnchorsHaveBeenInsertedDialog(); BATFeather.Wrappers().Backend().ContentBlocks().LinkSelectorWrapper().CancelEditingLinkSelector(); BATFeather.Wrappers().Backend().ContentBlocks().ContentBlocksWrapper().SaveChanges(); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().PublishPage(); }
public void AddAndRemoveChoicesToCheckBoxField() { BAT.Macros().NavigateTo().Modules().Forms(this.Culture); BAT.Wrappers().Backend().Forms().FormsDashboard().OpenFormFromTheGrid(FormName); ActiveBrowser.WaitUntilReady(); ActiveBrowser.WaitForAsyncOperations(); ActiveBrowser.RefreshDomTree(); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().EditWidget(CheckboxesField); BATFeather.Wrappers().Backend().Forms().FormsContentScreenWrapper().ChangeLabel(ChoiceText); BATFeather.Wrappers().Backend().Forms().FormsContentScreenWrapper().ClickToAddNewChoiceLink(); BATFeather.Wrappers().Backend().Forms().FormsContentScreenWrapper().AddNewChoiceLabel(NewChoice); BATFeather.Wrappers().Backend().Forms().FormsContentScreenWrapper().ClickToRemoveFirstChoiceLink(); BATFeather.Wrappers().Backend().Forms().FormsContentScreenWrapper().AddOtherChoice(); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().SaveChanges(); BAT.Wrappers().Backend().Forms().FormsContentScreen().PublishForm(); BAT.Macros().NavigateTo().CustomPage("~/" + PageName.ToLower(), true, this.Culture); Assert.IsTrue(ActiveBrowser.ContainsText(NewChoice), "Choice not found on the page"); Assert.IsFalse(ActiveBrowser.ContainsText(Choice), "Choice was not found on the page"); Assert.IsTrue(ActiveBrowser.ContainsText(OtherChoice), "Choice not found on the page"); Assert.IsTrue(ActiveBrowser.ContainsText(ChoiceText), "Choice not found on the page"); BATFeather.Wrappers().Frontend().Forms().FormsWrapper().SelectCheckbox(NewChoice); BATFeather.Wrappers().Frontend().Forms().FormsWrapper().SubmitForm(); BAT.Macros().NavigateTo().Modules().Forms(this.Culture); BAT.Wrappers().Backend().Forms().FormsDashboard().ViewFormResponses(FormName); BATFeather.Wrappers().Backend().Forms().FormsWrapper().VerifyNumberOfResponses(ExpectedResponsesCount1); BAT.Wrappers().Backend().Forms().FormsResponseScreen().SelectResponse(ExpectedResponsesCount1); BATFeather.Wrappers().Backend().Forms().FormsWrapper().VerifyResponseAuthorUsername(ExpectedAuthorName); BATFeather.Wrappers().Backend().Forms().FormsWrapper().VerifyResponseSubmitDate(); BATFeather.Wrappers().Backend().Forms().FormsWrapper().VerifyResponseMultipleChoiceAnswer(NewChoice); BAT.Macros().NavigateTo().CustomPage("~/" + PageName.ToLower(), true, this.Culture); BATFeather.Wrappers().Frontend().Forms().FormsWrapper().SelectOtherCheckboxButton(); BATFeather.Wrappers().Frontend().Forms().FormsWrapper().SetTextToOtherChoiceInCheckBoxField(OtherChoiceText); BATFeather.Wrappers().Frontend().Forms().FormsWrapper().SubmitForm(); BAT.Macros().NavigateTo().Modules().Forms(this.Culture); BAT.Wrappers().Backend().Forms().FormsDashboard().ViewFormResponses(FormName, TwoResponses); BATFeather.Wrappers().Backend().Forms().FormsWrapper().VerifyNumberOfResponses(ExpectedResponsesCount2); BAT.Wrappers().Backend().Forms().FormsResponseScreen().SelectResponse(ExpectedResponsesCount2); BATFeather.Wrappers().Backend().Forms().FormsWrapper().VerifyResponseAuthorUsername(ExpectedAuthorName); BATFeather.Wrappers().Backend().Forms().FormsWrapper().VerifyResponseSubmitDate(); BATFeather.Wrappers().Backend().Forms().FormsWrapper().VerifyResponseMultipleChoiceAnswer(OtherChoiceText); }
public void DeactivateAndActivateDynamicModuleVerifyPageToolbox() { this.moduleName = "Press Release"; BAT.Arrange(this.TestName).ExecuteArrangement("VerifyToolboxConfigBeforeDeactivate"); BAT.Arrange(this.TestName).ExecuteArrangement("DeactivateModule"); BAT.Macros().NavigateTo().Pages(this.Culture); BAT.Wrappers().Backend().Pages().PagesWrapper().OpenPageZoneEditor(PageName); Assert.IsFalse(BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().IsMvcWidgetPresentInToolbox(WidgetName)); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().PublishPage(); BAT.Arrange(this.TestName).ExecuteArrangement("ActivateModule"); BAT.Wrappers().Backend().Pages().PagesWrapper().OpenPageZoneEditor(PageName); Assert.IsTrue(BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().IsMvcWidgetPresentInToolbox(WidgetName)); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().PublishPage(); }
public void UseSharedContentBlockFromPage() { BAT.Macros().NavigateTo().Pages(this.Culture); BAT.Wrappers().Backend().Pages().PagesWrapper().OpenPageZoneEditor(PageName); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().SelectExtraOptionForWidget(OperationName); BATFeather.Wrappers().Backend().ContentBlocks().ContentBlocksShareWrapper().SelectContentBlock(ContentBlockTitle); this.VerifyIfSharedLabelExist(); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().PublishPage(); BAT.Macros().NavigateTo().Modules().ContentBlocks(this.Culture); this.VerifyIfContentBlockExist(ContentBlockTitle); this.VerifyLinkUsedOfContentBlockOnPage(); this.ClickLinkUsedOfContentBlockOnPage(); BAT.Wrappers().Backend().ContentBlocks().ContentBlocksWrapper().VerifyUsedPagesMessage(ExpectedCount); this.VerifyPagesThatUseSharedContentBlock(); BAT.Macros().NavigateTo().CustomPage("~/" + PageName.ToLower(), true, this.Culture); BATFeather.Wrappers().Frontend().ContentBlock().ContentBlockWrapper().VerifyContentOfContentBlockOnThePageFrontend(ContentBlockContent); }
public void OldAndNewContentBlockWidgetOnTheSamePage() { BAT.Macros().NavigateTo().Pages(this.Culture); BAT.Wrappers().Backend().Pages().PagesWrapper().OpenPageZoneEditor(PageName); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().EditWidget(NewContentBlockWidget); BATFeather.Wrappers().Backend().ContentBlocks().ContentBlocksWrapper().FillContentToContentBlockWidget(NewContentBlockContent); BATFeather.Wrappers().Backend().ContentBlocks().ContentBlocksWrapper().SaveChanges(); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().CheckWidgetContent(NewContentBlockWidget, NewContentBlockContent); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().EditWidget(OldContentBlockWidget); BAT.Wrappers().Backend().Pages().WidgetDesigners().ContentBlockDesigner().FillContentBlockContent(OldContentBlockContent); BAT.Wrappers().Backend().Pages().WidgetDesigners().ContentBlockDesigner().SaveEditedWidgetChanges(); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().CheckWidgetContent(OldContentBlockWidget, OldContentBlockContent); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().PublishPage(); BAT.Macros().NavigateTo().CustomPage("~/" + PageName.ToLower(), true, this.Culture); BATFeather.Wrappers().Frontend().ContentBlock().ContentBlockWrapper().VerifyContentOfContentBlockOnThePageFrontend(NewContentBlockContent); BAT.Wrappers().Frontend().ContentBlock().ContentBlockWrapper().VerifyContentOfContentBlockOnThePageFrontend(OldContentBlockContent); }
public void AddNewsWidgetToPageVerifyViewPermissions() { BAT.Macros().NavigateTo().Pages(this.Culture); BAT.Wrappers().Backend().Pages().PagesWrapper().OpenPageZoneEditor(PageName); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().SelectExtraOptionForWidget(OperationName); BAT.Wrappers().Backend().Permissions().PermissionsContentWrapper().ClickChangePermissionsButton(PermissionTypes.View); BAT.Wrappers().Backend().Permissions().PermissionsContentWrapper().SelectAndAddRole("Authenticated"); BAT.Wrappers().Backend().Permissions().PermissionsContentWrapper().ClickBackButton(); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().WaitUntilReady(); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().PublishPage(); BAT.Macros().User().LogOut(); ActiveBrowser.RefreshDomTree(); BAT.Macros().NavigateTo().CustomPage("~/" + PageName.ToLower(), false, culture: this.Culture); Assert.IsFalse(ActiveBrowser.ContainsText(NewsTitle), "News title was found but it shouldn't"); }
public void CheckSelectorsAfterUNPublishingNewsItem() { BAT.Macros().NavigateTo().Pages(this.Culture); BAT.Wrappers().Backend().Pages().PagesWrapper().OpenPageZoneEditor(PageName); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().EditWidget(WidgetName); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().SelectWhichItemsToDisplay(WhichNewsToDisplay); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().ClickSelectButton(); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().WaitForItemsToAppear(20); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().SelectItemsInFlatSelector(this.selectedNewsNames); var countOfSelectedItems = this.selectedNewsNames.Count(); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().CheckNotificationInSelectedTab(countOfSelectedItems); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().DoneSelecting(); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().VerifySelectedItemsFromFlatSelector(this.selectedNewsNames); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().SaveChanges(); foreach (var newsItem in this.newSelectedNewsNames) { BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().CheckWidgetContent(WidgetName, newsItem); } BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().PublishPage(); this.UnpublishNewsItem(); BAT.Macros().NavigateTo().Pages(this.Culture); BAT.Wrappers().Backend().Pages().PagesWrapper().OpenPageZoneEditor(PageName); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().EditWidget(WidgetName); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().VerifySelectedItemsFromFlatSelector(this.newSelectedNewsNames); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().ClickSelectButton(); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().WaitForItemsToAppear(3); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().OpenAllTab(); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().WaitForItemsToAppear(19); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().DoneSelecting(); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().SaveChanges(); foreach (var newsTitle in this.newSelectedNewsNames) { BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().CheckWidgetContent(WidgetName, newsTitle); } BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().PublishPage(); BAT.Macros().NavigateTo().CustomPage("~/" + PageName.ToLower(), true, this.Culture); Assert.IsTrue(BATFeather.Wrappers().Frontend().News().NewsWrapper().IsNewsTitlesPresentOnThePageFrontend(this.newSelectedNewsNames)); }
public void VerifyPagingOnFrontendPageForImageGalleryWidget() { RuntimeSettingsModificator.ExecuteWithClientTimeout(800000, () => BAT.Macros().NavigateTo().CustomPage("~/sitefinity/pages", true, null, new HtmlFindExpression("class=~sfMain"))); BAT.Macros().NavigateTo().Pages(this.Culture); BAT.Wrappers().Backend().Pages().PagesWrapper().OpenPageZoneEditor(PageName); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().EditWidget(WidgetName); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().SwitchToListSettingsTab(); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().VerifyCheckedRadioButtonOption(WidgetDesignerRadioButtonIds.UsePaging); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().ChangePagingOrLimitValue("2", "Paging"); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().VerifyPageValue("2", "Paging"); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().VerifyPageValue("20", "Limit"); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().SaveChanges(); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().EditWidget(WidgetName); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().SwitchToListSettingsTab(); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().VerifyCheckedRadioButtonOption(WidgetDesignerRadioButtonIds.UsePaging); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().VerifyPageValue("2", "Paging"); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().VerifyPageValue("20", "Limit"); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().PressCancelButton(); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().PublishPage(); BAT.Macros().NavigateTo().CustomPage("~/" + PageName.ToLower(), true, this.Culture); BATFeather.Wrappers().Frontend().ImageGallery().ImageGalleryWrapper().VerifyImageIsPresent(ImageAltText5); BATFeather.Wrappers().Frontend().ImageGallery().ImageGalleryWrapper().VerifyImageIsPresent(ImageAltText4); BATFeather.Wrappers().Frontend().ImageGallery().ImageGalleryWrapper().VerifyImageIsNotPresent(ImageAltText3); BATFeather.Wrappers().Frontend().ImageGallery().ImageGalleryWrapper().VerifyImageIsNotPresent(ImageAltText2); BATFeather.Wrappers().Frontend().ImageGallery().ImageGalleryWrapper().VerifyImageIsNotPresent(ImageAltText1); BATFeather.Wrappers().Frontend().CommonWrapper().NavigateToPageUsingPager("2", 3); BATFeather.Wrappers().Frontend().ImageGallery().ImageGalleryWrapper().VerifyImageIsPresent(ImageAltText3); BATFeather.Wrappers().Frontend().ImageGallery().ImageGalleryWrapper().VerifyImageIsPresent(ImageAltText2); BATFeather.Wrappers().Frontend().ImageGallery().ImageGalleryWrapper().VerifyImageIsNotPresent(ImageAltText5); BATFeather.Wrappers().Frontend().ImageGallery().ImageGalleryWrapper().VerifyImageIsNotPresent(ImageAltText4); BATFeather.Wrappers().Frontend().ImageGallery().ImageGalleryWrapper().VerifyImageIsNotPresent(ImageAltText1); BATFeather.Wrappers().Frontend().CommonWrapper().NavigateToPageUsingPager("3", 3); BATFeather.Wrappers().Frontend().ImageGallery().ImageGalleryWrapper().VerifyImageIsPresent(ImageAltText1); BATFeather.Wrappers().Frontend().ImageGallery().ImageGalleryWrapper().VerifyImageIsNotPresent(ImageAltText5); BATFeather.Wrappers().Frontend().ImageGallery().ImageGalleryWrapper().VerifyImageIsNotPresent(ImageAltText4); BATFeather.Wrappers().Frontend().ImageGallery().ImageGalleryWrapper().VerifyImageIsNotPresent(ImageAltText3); BATFeather.Wrappers().Frontend().ImageGallery().ImageGalleryWrapper().VerifyImageIsNotPresent(ImageAltText2); BATFeather.Wrappers().Frontend().CommonWrapper().NavigateToPageUsingPager("1", 3); BATFeather.Wrappers().Frontend().ImageGallery().ImageGalleryWrapper().VerifyImageIsPresent(ImageAltText5); BATFeather.Wrappers().Frontend().ImageGallery().ImageGalleryWrapper().VerifyImageIsPresent(ImageAltText4); BATFeather.Wrappers().Frontend().ImageGallery().ImageGalleryWrapper().VerifyImageIsNotPresent(ImageAltText3); BATFeather.Wrappers().Frontend().ImageGallery().ImageGalleryWrapper().VerifyImageIsNotPresent(ImageAltText2); BATFeather.Wrappers().Frontend().ImageGallery().ImageGalleryWrapper().VerifyImageIsNotPresent(ImageAltText1); BAT.Macros().NavigateTo().Pages(this.Culture); }
public void AddNewLayoutFileToDefaultPackage() { BAT.Macros().User().EnsureAdminLoggedIn(); BAT.Arrange(this.TestName).ExecuteArrangement("AddNewLayoutFile"); BAT.Macros().NavigateTo().Design().PageTemplates(); BAT.Wrappers().Backend().PageTemplates().PageTemplateMainScreen().IsItemPresentInGridView(TemplateTitle); BAT.Wrappers().Backend().PageTemplates().PageTemplateMainScreen().OpenTemplateEditor(TemplateTitle); bool isTextPresent = BATFrontend.Wrappers().Backend().PageTemplates().PageTemplateEditor().IsTextPresentInTemplateMainContainer(LayoutText); Assert.IsTrue(isTextPresent, "Layout template text was not found"); bool isPlaceholderPresent = BATFrontend.Wrappers().Backend().PageTemplates().PageTemplateEditor().IsPlaceHolderPresent(PlaceHolderId); Assert.IsTrue(isPlaceholderPresent, "Placeholder not found"); }
public void PublishUnpublishFormInUseVerifyFrontend() { BAT.Macros().NavigateTo().CustomPage("~/" + FeatherGlobals.BootstrapPageName.ToLower(), true, this.Culture, new HtmlFindExpression("TagName=button")); BATFeather.Wrappers().Frontend().Forms().FormsWrapper().VerifySubmitButtonIsVisible(); BATFeather.Wrappers().Frontend().Forms().FormsWrapper().VerifyMultipleChoiceFieldContainerIsVisible(); BATFeather.Wrappers().Frontend().Forms().FormsWrapper().VerifyMultipleChoiceFieldLabelIsVisible(FeatherGlobals.SelectAChoiceLabelName); BAT.Macros().NavigateTo().Modules().Forms(this.Culture); BAT.Wrappers().Backend().Forms().FormsDashboard().UnpublishFormFromActionsMenu(FeatherGlobals.FormName); BAT.Macros().NavigateTo().CustomPage("~/" + FeatherGlobals.BootstrapPageName.ToLower(), true, this.Culture); BATFeather.Wrappers().Frontend().Forms().FormsWrapper().VerifyMessageIsDisplayedAfterFormIsDeleted(); BAT.Macros().NavigateTo().Modules().Forms(this.Culture); BAT.Wrappers().Backend().Forms().FormsDashboard().PublishFormFromActionsMenu(FeatherGlobals.FormName); BAT.Macros().NavigateTo().CustomPage("~/" + FeatherGlobals.BootstrapPageName.ToLower(), true, this.Culture, new HtmlFindExpression("TagName=button")); BATFeather.Wrappers().Frontend().Forms().FormsWrapper().VerifySubmitButtonIsVisible(); BATFeather.Wrappers().Frontend().Forms().FormsWrapper().VerifyMultipleChoiceFieldContainerIsVisible(); BATFeather.Wrappers().Frontend().Forms().FormsWrapper().VerifyMultipleChoiceFieldLabelIsVisible(FeatherGlobals.SelectAChoiceLabelName); }
public void DragAndDropSubscribeFormWidgetOnPageAndSelectMailingList() { BAT.Macros().NavigateTo().Pages(this.Culture); BAT.Wrappers().Backend().Pages().PagesWrapper().OpenPageZoneEditor(PageName); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().AddWidgetToPlaceHolderPureMvcMode(WidgetName); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().EditWidget(WidgetName); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().ClickSelectButton(); BATFeather.Wrappers().Backend().EmailCampaigns().SubscribeFormWrapper().SelectItemsInFlatSelector(MailingList); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().DoneSelecting(); BATFeather.Wrappers().Backend().ContentBlocks().ContentBlocksWrapper().SaveChanges(); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().PublishPage(); BAT.Macros().NavigateTo().CustomPage("~/" + PageName.ToLower(), false, this.Culture); BATFeather.Wrappers().Frontend().EmailCampaigns().SubscibeFormWrapper().VerifySubscribeMessageOnTheFrontend(); BATFeather.Wrappers().Frontend().EmailCampaigns().SubscibeFormWrapper().FillEmail(SubscriberEmail); BATFeather.Wrappers().Frontend().EmailCampaigns().SubscibeFormWrapper().ClickSubscribeButton(); BATFeather.Wrappers().Frontend().EmailCampaigns().SubscibeFormWrapper().VerifySuccessfullySubscribeMessageOnTheFrontend(SubscriberEmail); }
public void TryToUnsubscribeNotExistingSubscriber() { BAT.Macros().NavigateTo().Pages(this.Culture); BAT.Wrappers().Backend().Pages().PagesWrapper().OpenPageZoneEditor(PageName); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().EditWidget(WidgetName); BATFeather.Wrappers().Backend().EmailCampaigns().UnsubscribeWrapper().SelectEmailAddress(); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().ClickSelectButton(); BATFeather.Wrappers().Backend().EmailCampaigns().SubscribeFormWrapper().SelectItemsInFlatSelector(MailingList); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().DoneSelecting(); BATFeather.Wrappers().Backend().ContentBlocks().ContentBlocksWrapper().SaveChanges(); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().PublishPage(); BAT.Macros().NavigateTo().CustomPage("~/" + PageName.ToLower(), false, this.Culture); BATFeather.Wrappers().Frontend().EmailCampaigns().UnsubscribeWrapper().VerifyUnsubscribeMessageOnTheFrontend(); BATFeather.Wrappers().Frontend().EmailCampaigns().SubscibeFormWrapper().FillEmail(UnsubscriberEmail); BATFeather.Wrappers().Frontend().EmailCampaigns().UnsubscribeWrapper().ClickUnsubscribeButton(); BATFeather.Wrappers().Frontend().EmailCampaigns().UnsubscribeWrapper().VerifyNotExistingEmailMessageOnTheFrontend(UnsubscriberEmail); }
public void SelectItemInDynamicWidgetFromDifferentProvider() { BAT.Macros().NavigateTo().Pages(this.Culture); BAT.Wrappers().Backend().Pages().PagesWrapper().OpenPageZoneEditor(PageName); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().EditWidget(WidgetName); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().SelectProvider(SecondProviderName); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().SelectWhichItemsToDisplay(WhichItemsToDisplay); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().ClickSelectButton(); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().WaitForItemsToAppear(ItemsCount); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().SelectItemsInFlatSelector(this.itemsTitles[0]); BATFeather.Wrappers().Backend().Widgets().SelectorsWrapper().DoneSelecting(); BATFeather.Wrappers().Backend().Widgets().WidgetDesignerWrapper().SaveChanges(); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().CheckWidgetContent(WidgetName, this.itemsTitles[0]); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().PublishPage(); BAT.Macros().NavigateTo().CustomPage("~/" + PageName.ToLower(), true, this.Culture); Assert.IsTrue(BATFeather.Wrappers().Frontend().ModuleBuilder().ModuleBuilderWrapper().VerifyDynamicContentPresentOnTheFrontend(this.itemsTitles)); }
public void DeactivateFeatherModule() { BAT.Arrange(this.TestName).ExecuteArrangement("DeactivateModule"); this.VerifyPageBackend(PageName, WidgetName, ContentBlockContent, false); BAT.Macros().NavigateTo().CustomPage("~/" + PageName.ToLower(), true, this.Culture); BAT.Wrappers().Backend().ModulesAndServices().FrontendWrapper().VerifyFrontendForNotExistingModule(ContentBlockContent, PageName); BAT.Arrange(this.TestName).ExecuteArrangement("ActivateModule"); this.VerifyPageBackend(PageName, WidgetName, ContentBlockContent, true); BAT.Macros().NavigateTo().CustomPage("~/" + PageName.ToLower(), true, this.Culture); BATFeather.Wrappers().Frontend().ContentBlock().ContentBlockWrapper().VerifyContentOfContentBlockOnThePageFrontend(ContentBlockContent); }
public void PreviewFormWithTextField() { BAT.Macros().NavigateTo().Modules().Forms(this.Culture); BAT.Wrappers().Backend().Forms().FormsDashboard().OpenFormFromTheGrid(FormName); ActiveBrowser.WaitUntilReady(); ActiveBrowser.WaitForAsyncOperations(); ActiveBrowser.RefreshDomTree(); BATFeather.Wrappers().Backend().Pages().PageZoneEditorWrapper().EditWidget(TextField); BATFeather.Wrappers().Backend().Forms().FormsContentScreenWrapper().ChangeTexboxLabel(TextFieldLabel); BATFeather.Wrappers().Backend().ContentBlocks().ContentBlocksWrapper().SaveChanges(); BATFeather.Wrappers().Backend().Forms().FormsContentScreenWrapper().ClickPreviewButton(); ActiveBrowser.WaitUntilReady(); ActiveBrowser.RefreshDomTree(); ActiveBrowser.WaitUntilReady(); Assert.IsTrue(ActiveBrowser.ContainsText(TextFieldLabel), "Text was not found on the page"); BATFeather.Wrappers().Frontend().Forms().FormsWrapper().VerifyTextboxFieldContainerIsVisible(); }
public void MultipleTagsSelectorVerifySelectionAfterSwitchingToAdvancedSettings() { BAT.Macros().NavigateTo().Pages(); BAT.Wrappers().Backend().Pages().PagesWrapper().OpenPageZoneEditor(PageName); BATFrontend.Wrappers().Backend().Pages().PageZoneEditorWrapper().EditWidget(WidgetCaption); BATFrontend.Wrappers().Backend().Widgets().WidgetsWrapper().WaitForSaveButtonToAppear(); BATFrontend.Wrappers().Backend().Widgets().WidgetsWrapper().SelectContent(TagSelectorName); BATFrontend.Wrappers().Backend().Widgets().WidgetsWrapper().WaitForItemsToAppear(TagItemsToAppearCount); BATFrontend.Wrappers().Backend().Widgets().WidgetsWrapper().SelectItem(this.selectedTagNames); BATFrontend.Wrappers().Backend().Widgets().WidgetsWrapper().DoneSelecting(); BATFrontend.Wrappers().Backend().Widgets().WidgetsWrapper().VerifySelectedItemInMultipleSelectors(this.selectedTagNames); BATFrontend.Wrappers().Backend().Widgets().WidgetsWrapper().ClickAdvancedButton(); BATFrontend.Wrappers().Backend().Widgets().WidgetsWrapper().ClickSelectorButton(); BATFrontend.Wrappers().Backend().Widgets().WidgetsWrapper().VerifySelectedItemInMultipleSelectors(this.selectedTagNames); BATFrontend.Wrappers().Backend().Widgets().WidgetsWrapper().ClickSaveButton(); BAT.Wrappers().Backend().Pages().PageZoneEditorWrapper().PublishPage(); }
public void ImportModuleWithEditedWidgetTemplate() { RuntimeSettingsModificator.ExecuteWithClientTimeout(200000, () => BAT.Macros().NavigateTo().Design().WidgetTemplates()); this.SelectAllTemplatesFromTheSidebar(); BAT.Wrappers().Backend().ModuleBuilder().ContentTypePageActionsWrapper().OpenWidgetTemplate(MVCWidgetTemplate); BAT.Wrappers().Backend().ModuleBuilder().ContentTypePageActionsWrapper().EditFrame.WaitForAsyncOperations(); BAT.Wrappers().Backend().ModuleBuilder().ContentTypePageActionsWrapper().VerifyWidgetTemplateContent(EditedWidgetTemplate); BAT.Wrappers().Backend().ModuleBuilder().ContentTypePageActionsWrapper().ClickSaveChangesLink(); Manager.Current.ActiveBrowser.WaitUntilReady(); Manager.Current.ActiveBrowser.WaitForAsyncOperations(); BAT.Wrappers().Backend().ModuleBuilder().ContentTypePageActionsWrapper().OpenWidgetTemplate(MVCWidgetTemplate2); BAT.Wrappers().Backend().ModuleBuilder().ContentTypePageActionsWrapper().EditFrame.WaitForAsyncOperations(); BAT.Wrappers().Backend().ModuleBuilder().ContentTypePageActionsWrapper().VerifyWidgetTemplateContent(EditedWidgetTemplate); BAT.Wrappers().Backend().ModuleBuilder().ContentTypePageActionsWrapper().ClickSaveChangesLink(); Manager.Current.ActiveBrowser.WaitUntilReady(); Manager.Current.ActiveBrowser.WaitForAsyncOperations(); }