Search in sources :

Example 16 with InBrowser

use of com.wikia.webdriver.common.core.annotations.InBrowser in project selenium-tests by Wikia.

the class ReportingPostTests method userOnDesktopCanNotSeeDeletedPostOnPostsListPage.

@Test(groups = "discussions-loggedInUsersDesktopReporting")
@Execute(asUser = User.USER)
@InBrowser(browser = Browser.FIREFOX, browserSize = DESKTOP_RESOLUTION)
public void userOnDesktopCanNotSeeDeletedPostOnPostsListPage() {
    final PostEntity.Data data = createAndReportAndDeletePostRemotely();
    final PostsListPage page = openPostListPageAndWaitUntilLoaded();
    final PostEntity postEntity = page.getPost().findPostById(data.getId());
    assertNull(postEntity, NOT_VISIBLE_DELETED_POST_MESSAGE);
}
Also used : PostsListPage(com.wikia.webdriver.elements.mercury.pages.discussions.PostsListPage) PostEntity(com.wikia.webdriver.elements.mercury.components.discussions.common.PostEntity) Execute(com.wikia.webdriver.common.core.annotations.Execute) Test(org.testng.annotations.Test) InBrowser(com.wikia.webdriver.common.core.annotations.InBrowser)

Example 17 with InBrowser

use of com.wikia.webdriver.common.core.annotations.InBrowser in project selenium-tests by Wikia.

the class ReportingPostTests method anonUserOnMobileCanNotSeeDeletedPostOnUserPostsPage.

@Test(groups = "discussions-anonUserMobileReporting")
@Execute(asUser = User.ANONYMOUS)
@InBrowser(browser = Browser.CHROME, emulator = Emulator.GOOGLE_NEXUS_5)
public void anonUserOnMobileCanNotSeeDeletedPostOnUserPostsPage() {
    final PostEntity.Data data = createAndReportAndDeletePostRemotely();
    final UserPostsPage open = openUserPostsAndWaitUntilLoaded(data.getAuthorId());
    final PostEntity post = open.getPost().findPostById(data.getId());
    assertNull(post, ANON_NOT_VISIBLE_DELETED_POST_MESSAGE);
}
Also used : UserPostsPage(com.wikia.webdriver.elements.mercury.pages.discussions.UserPostsPage) PostEntity(com.wikia.webdriver.elements.mercury.components.discussions.common.PostEntity) Execute(com.wikia.webdriver.common.core.annotations.Execute) Test(org.testng.annotations.Test) InBrowser(com.wikia.webdriver.common.core.annotations.InBrowser)

Example 18 with InBrowser

use of com.wikia.webdriver.common.core.annotations.InBrowser in project selenium-tests by Wikia.

the class ReportingPostTests method anonUserOnMobileCanNotReportPostOnPostDetailsPage.

@Test(groups = "discussions-anonUserMobileReporting")
@Execute(asUser = User.ANONYMOUS)
@InBrowser(browser = Browser.CHROME, emulator = Emulator.GOOGLE_NEXUS_5)
public void anonUserOnMobileCanNotReportPostOnPostDetailsPage() {
    final PostDetailsPage page = openDefaultPostDetailsWaitingUtilLoaded();
    assertFalse(isReportPostOptionAvailableOn(page), NO_REPORT_POST_OPTION_MESSAGE);
}
Also used : PostDetailsPage(com.wikia.webdriver.elements.mercury.pages.discussions.PostDetailsPage) Execute(com.wikia.webdriver.common.core.annotations.Execute) Test(org.testng.annotations.Test) InBrowser(com.wikia.webdriver.common.core.annotations.InBrowser)

Example 19 with InBrowser

use of com.wikia.webdriver.common.core.annotations.InBrowser in project selenium-tests by Wikia.

the class ReportingPostTests method anonUserOnDesktopCanNotSeeReportedPostOnPostsListPage.

@Test(groups = "discussions-anonUserDesktopReporting")
@Execute(asUser = User.ANONYMOUS)
@InBrowser(browser = Browser.FIREFOX, browserSize = DESKTOP_RESOLUTION)
public void anonUserOnDesktopCanNotSeeReportedPostOnPostsListPage() {
    createAndReportPostRemotelyAsFirstUser();
    final PostsListPage page = openPostListPageAndWaitUntilLoaded();
    assertFalse(postHasReportedIndicator(page), NO_REPORTED_INDICATOR_ON_POST_MESSAGE);
}
Also used : PostsListPage(com.wikia.webdriver.elements.mercury.pages.discussions.PostsListPage) Execute(com.wikia.webdriver.common.core.annotations.Execute) Test(org.testng.annotations.Test) InBrowser(com.wikia.webdriver.common.core.annotations.InBrowser)

Example 20 with InBrowser

use of com.wikia.webdriver.common.core.annotations.InBrowser in project selenium-tests by Wikia.

the class ReportingPostTests method anonUserOnMobileCanNotSeeDeletedPostOnPostDetailsPage.

@Test(groups = "discussions-anonUserMobileReporting")
@Execute(asUser = User.ANONYMOUS)
@InBrowser(browser = Browser.CHROME, emulator = Emulator.GOOGLE_NEXUS_5)
public void anonUserOnMobileCanNotSeeDeletedPostOnPostDetailsPage() {
    final PostEntity.Data data = createAndReportAndDeletePostRemotely();
    final PostDetailsPage page = openPostDetailsPageAndWaitUntilLoaded(data.getId());
    assertTrue(page.getErrorMessages().isErrorMessagePresent(), ANON_NOT_VISIBLE_DELETED_POST_MESSAGE);
}
Also used : PostDetailsPage(com.wikia.webdriver.elements.mercury.pages.discussions.PostDetailsPage) PostEntity(com.wikia.webdriver.elements.mercury.components.discussions.common.PostEntity) Execute(com.wikia.webdriver.common.core.annotations.Execute) Test(org.testng.annotations.Test) InBrowser(com.wikia.webdriver.common.core.annotations.InBrowser)

Aggregations

InBrowser (com.wikia.webdriver.common.core.annotations.InBrowser)184 Test (org.testng.annotations.Test)180 Execute (com.wikia.webdriver.common.core.annotations.Execute)146 PostEntity (com.wikia.webdriver.elements.mercury.components.discussions.common.PostEntity)50 PostDetailsPage (com.wikia.webdriver.elements.mercury.pages.discussions.PostDetailsPage)35 PostsListPage (com.wikia.webdriver.elements.mercury.pages.discussions.PostsListPage)26 GuidelinesPage (com.wikia.webdriver.elements.mercury.pages.discussions.GuidelinesPage)17 AdsBaseObject (com.wikia.webdriver.pageobjectsfactory.pageobject.adsbase.AdsBaseObject)15 NetworkTrafficDump (com.wikia.webdriver.common.core.annotations.NetworkTrafficDump)13 MoreOptionsPopOver (com.wikia.webdriver.elements.mercury.components.discussions.common.MoreOptionsPopOver)12 SearchResultsPage (com.wikia.webdriver.elements.mercury.pages.SearchResultsPage)12 LightboxComponentObject (com.wikia.webdriver.pageobjectsfactory.componentobject.lightbox.LightboxComponentObject)12 VideoFanTakeover (com.wikia.webdriver.pageobjectsfactory.componentobject.ad.VideoFanTakeover)11 CategoriesFieldset (com.wikia.webdriver.elements.mercury.components.discussions.common.category.CategoriesFieldset)10 UserPostsPage (com.wikia.webdriver.elements.mercury.pages.discussions.UserPostsPage)10 AdsFandomObject (com.wikia.webdriver.pageobjectsfactory.pageobject.adsbase.AdsFandomObject)9 RelatedIssue (com.wikia.webdriver.common.core.annotations.RelatedIssue)7 CategoryPill (com.wikia.webdriver.elements.mercury.components.discussions.common.category.CategoryPill)7 PostActionsRow (com.wikia.webdriver.elements.mercury.components.discussions.common.PostActionsRow)6 ReplyCreator (com.wikia.webdriver.elements.mercury.components.discussions.common.ReplyCreator)5