Search in sources :

Example 1 with DiscussionsHeader

use of com.wikia.webdriver.elements.mercury.components.discussions.mobile.DiscussionsHeader in project selenium-tests by Wikia.

the class SortingTests method userCanSwitchBetweenLatestAndTrendingInDropdown.

/**
   * TESTING METHODS SECTION
   */
private void userCanSwitchBetweenLatestAndTrendingInDropdown() {
    PostsListPage page = new PostsListPage().open();
    FiltersPopOver filtersPopOver = page.getFiltersPopOver();
    DiscussionsHeader discussionsHeader = page.getDiscussionsHeader();
    discussionsHeader.clickSortButtonOnMobile();
    Assertion.assertTrue(filtersPopOver.isSortListVisibleMobile());
    filtersPopOver.clickLatestLinkOnMobile();
    filtersPopOver.clickApplyButton();
    new Loading(driver).handleAsyncPageReload();
    discussionsHeader.clickSortButtonOnMobile();
    filtersPopOver.clickTrendingOptionInSortMenu();
    filtersPopOver.clickApplyButton();
    new Loading(driver).handleAsyncPageReload();
}
Also used : Loading(com.wikia.webdriver.elements.mercury.components.Loading) FiltersPopOver(com.wikia.webdriver.elements.mercury.components.discussions.mobile.FiltersPopOver) PostsListPage(com.wikia.webdriver.elements.mercury.pages.discussions.PostsListPage) DiscussionsHeader(com.wikia.webdriver.elements.mercury.components.discussions.mobile.DiscussionsHeader)

Aggregations

Loading (com.wikia.webdriver.elements.mercury.components.Loading)1 DiscussionsHeader (com.wikia.webdriver.elements.mercury.components.discussions.mobile.DiscussionsHeader)1 FiltersPopOver (com.wikia.webdriver.elements.mercury.components.discussions.mobile.FiltersPopOver)1 PostsListPage (com.wikia.webdriver.elements.mercury.pages.discussions.PostsListPage)1