Search in sources :

Example 41 with Execute

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

the class FollowArticleTests method unfollowArticleIfFollowed.

@Test
@Execute(asUser = User.USER)
public void unfollowArticleIfFollowed() {
    new ArticleContent().push(PageContent.ARTICLE_TEXT, ARTICLE_NAME);
    ArticlePageObject article = new ArticlePageObject().open(ARTICLE_NAME);
    WatchPageObject watch = article.unfollowArticle();
    watch.confirmWatchUnwatch();
    article.verifyPageUnfollowed();
}
Also used : ArticleContent(com.wikia.webdriver.common.core.api.ArticleContent) ArticlePageObject(com.wikia.webdriver.pageobjectsfactory.pageobject.article.ArticlePageObject) WatchPageObject(com.wikia.webdriver.pageobjectsfactory.pageobject.special.watch.WatchPageObject) Execute(com.wikia.webdriver.common.core.annotations.Execute) Test(org.testng.annotations.Test)

Example 42 with Execute

use of com.wikia.webdriver.common.core.annotations.Execute 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 43 with Execute

use of com.wikia.webdriver.common.core.annotations.Execute 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 44 with Execute

use of com.wikia.webdriver.common.core.annotations.Execute 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 45 with Execute

use of com.wikia.webdriver.common.core.annotations.Execute 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)

Aggregations

Execute (com.wikia.webdriver.common.core.annotations.Execute)413 Test (org.testng.annotations.Test)402 InBrowser (com.wikia.webdriver.common.core.annotations.InBrowser)146 WikiBasePageObject (com.wikia.webdriver.pageobjectsfactory.pageobject.WikiBasePageObject)72 ArticlePageObject (com.wikia.webdriver.pageobjectsfactory.pageobject.article.ArticlePageObject)68 VisualEditModePageObject (com.wikia.webdriver.pageobjectsfactory.pageobject.article.editmode.VisualEditModePageObject)58 ArticleContent (com.wikia.webdriver.common.core.api.ArticleContent)55 PostEntity (com.wikia.webdriver.elements.mercury.components.discussions.common.PostEntity)50 PostDetailsPage (com.wikia.webdriver.elements.mercury.pages.discussions.PostDetailsPage)35 RelatedIssue (com.wikia.webdriver.common.core.annotations.RelatedIssue)30 InteractiveMapsPageObject (com.wikia.webdriver.pageobjectsfactory.pageobject.special.interactivemaps.InteractiveMapsPageObject)30 PostsListPage (com.wikia.webdriver.elements.mercury.pages.discussions.PostsListPage)26 InfoboxBuilderPage (com.wikia.webdriver.elements.mercury.pages.InfoboxBuilderPage)24 InteractiveMapPageObject (com.wikia.webdriver.pageobjectsfactory.pageobject.special.interactivemaps.InteractiveMapPageObject)23 VetOptionsComponentObject (com.wikia.webdriver.pageobjectsfactory.componentobject.vet.VetOptionsComponentObject)22 VetAddVideoComponentObject (com.wikia.webdriver.pageobjectsfactory.componentobject.vet.VetAddVideoComponentObject)21 MiniEditorComponentObject (com.wikia.webdriver.pageobjectsfactory.componentobject.minieditor.MiniEditorComponentObject)19 ForumPage (com.wikia.webdriver.pageobjectsfactory.pageobject.forumpageobject.ForumPage)18 GuidelinesPage (com.wikia.webdriver.elements.mercury.pages.discussions.GuidelinesPage)17 MessageWall (com.wikia.webdriver.pageobjectsfactory.pageobject.messagewall.MessageWall)17