Search in sources :

Example 21 with PostsListPage

use of com.wikia.webdriver.elements.mercury.pages.discussions.PostsListPage in project selenium-tests by Wikia.

the class LockingPostTests method findMoreOptionsOnPostsListPage.

private MoreOptionsPopOver findMoreOptionsOnPostsListPage() {
    PostEntity.Data data = DiscussionsOperations.using(User.USER, driver).createPostWithUniqueData();
    final PageWithPosts page = new PostsListPage().open();
    return findMoreOptions(page, data);
}
Also used : PostsListPage(com.wikia.webdriver.elements.mercury.pages.discussions.PostsListPage) PageWithPosts(com.wikia.webdriver.elements.mercury.pages.discussions.PageWithPosts) PostEntity(com.wikia.webdriver.elements.mercury.components.discussions.common.PostEntity)

Example 22 with PostsListPage

use of com.wikia.webdriver.elements.mercury.pages.discussions.PostsListPage in project selenium-tests by Wikia.

the class NavigatingTests method clickUsernameLoadsUserPage.

private void clickUsernameLoadsUserPage() {
    PostsListPage page = new PostsListPage().open();
    page.getPost().clickUsernameLink();
    Assertion.assertTrue(driver.getCurrentUrl().contains(URLsContent.USER_PROFILE.replace("%userName%", "")));
}
Also used : PostsListPage(com.wikia.webdriver.elements.mercury.pages.discussions.PostsListPage)

Example 23 with PostsListPage

use of com.wikia.webdriver.elements.mercury.pages.discussions.PostsListPage in project selenium-tests by Wikia.

the class NavigatingTests method backToWiki.

/**
   * TESTING METHODS SECTION
   */
private void backToWiki() {
    PostsListPage page = new PostsListPage().open();
    BackButtons backButtons = page.open().getBackButtons();
    backButtons.clickBackToWikiLink();
    Assertion.assertTrue(page.isWikiFirstHeaderVisible());
    Assertion.assertTrue(driver.getCurrentUrl().contains(wikiURL));
}
Also used : BackButtons(com.wikia.webdriver.elements.mercury.components.discussions.desktop.BackButtons) PostsListPage(com.wikia.webdriver.elements.mercury.pages.discussions.PostsListPage)

Example 24 with PostsListPage

use of com.wikia.webdriver.elements.mercury.pages.discussions.PostsListPage in project selenium-tests by Wikia.

the class PromotingTests method findPromoting.

/**
   * TESTING METHODS SECTION
   */
private Promoting findPromoting() {
    String siteId = Discussions.excractSiteIdFromWikiName(MercuryWikis.FALLOUT);
    PostsListPage page = new PostsListPage().open(siteId);
    return page.getPromoting();
}
Also used : PostsListPage(com.wikia.webdriver.elements.mercury.pages.discussions.PostsListPage)

Example 25 with PostsListPage

use of com.wikia.webdriver.elements.mercury.pages.discussions.PostsListPage in project selenium-tests by Wikia.

the class ZeroErrorStateTests method userSeesProperMessageWhenOpensEmptyPostsListPage.

private void userSeesProperMessageWhenOpensEmptyPostsListPage() {
    ErrorMessages errorMessage = new PostsListPage().open().getErrorMessages();
    Assertion.assertTrue(errorMessage.isEmptyPostsListMessageDisplayed());
    Assertion.assertEquals(errorMessage.getEmptyPostsListMessageText(), "No posts yet. Get the discussion started, create the first post now!");
}
Also used : ErrorMessages(com.wikia.webdriver.elements.mercury.components.discussions.common.ErrorMessages) PostsListPage(com.wikia.webdriver.elements.mercury.pages.discussions.PostsListPage)

Aggregations

PostsListPage (com.wikia.webdriver.elements.mercury.pages.discussions.PostsListPage)46 Execute (com.wikia.webdriver.common.core.annotations.Execute)26 InBrowser (com.wikia.webdriver.common.core.annotations.InBrowser)26 Test (org.testng.annotations.Test)26 CategoryPill (com.wikia.webdriver.elements.mercury.components.discussions.common.category.CategoryPill)11 PostEntity (com.wikia.webdriver.elements.mercury.components.discussions.common.PostEntity)10 CategoriesFieldset (com.wikia.webdriver.elements.mercury.components.discussions.common.category.CategoriesFieldset)10 Loading (com.wikia.webdriver.elements.mercury.components.Loading)3 PostsCreatorDesktop (com.wikia.webdriver.elements.mercury.components.discussions.desktop.PostsCreatorDesktop)3 Post (com.wikia.webdriver.elements.mercury.components.discussions.common.Post)2 ErrorMessages (com.wikia.webdriver.elements.mercury.components.discussions.common.ErrorMessages)1 BackButtons (com.wikia.webdriver.elements.mercury.components.discussions.desktop.BackButtons)1 SortingFiltersOnDesktop (com.wikia.webdriver.elements.mercury.components.discussions.desktop.SortingFiltersOnDesktop)1 DiscussionsHeader (com.wikia.webdriver.elements.mercury.components.discussions.mobile.DiscussionsHeader)1 FiltersPopOver (com.wikia.webdriver.elements.mercury.components.discussions.mobile.FiltersPopOver)1 PostsCreatorMobile (com.wikia.webdriver.elements.mercury.components.discussions.mobile.PostsCreatorMobile)1 PageWithPosts (com.wikia.webdriver.elements.mercury.pages.discussions.PageWithPosts)1