Search in sources :

Example 1 with CreationTicket

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

the class ArticleSourceModeTests method RTE_021_YoutubeTag_Publish.

@CreationTicket(ticketID = "CONCF-626")
@Test(groups = { "RTE_extended_4", "RTE_extended_021" })
public void RTE_021_YoutubeTag_Publish() {
    WikiBasePageObject base = new WikiBasePageObject();
    String articleName = PageContent.ARTICLE_NAME_PREFIX + base.getTimeStamp();
    ArticlePageObject article = new ArticlePageObject().open(articleName);
    SourceEditModePageObject source = article.openCurrectArticleSourceMode();
    YoutubeVideo video = YoutubeVideoProvider.getLatestVideoForQuery("water");
    String videoID = video.getID();
    source.addContentInSourceMode("<youtube>\n" + videoID + "\n</youtube>");
    article = source.clickPublishButton();
    article.verifyArticleTitle(articleName);
}
Also used : ArticlePageObject(com.wikia.webdriver.pageobjectsfactory.pageobject.article.ArticlePageObject) SourceEditModePageObject(com.wikia.webdriver.pageobjectsfactory.pageobject.article.editmode.SourceEditModePageObject) WikiBasePageObject(com.wikia.webdriver.pageobjectsfactory.pageobject.WikiBasePageObject) YoutubeVideo(com.wikia.webdriver.common.core.video.YoutubeVideo) CreationTicket(com.wikia.webdriver.common.core.annotations.CreationTicket) Test(org.testng.annotations.Test)

Example 2 with CreationTicket

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

the class ArticleSourceModeTests method RTE_020_YoutubeTag_Preview.

@CreationTicket(ticketID = "CONCF-626")
@Test(groups = { "RTE_extended_4", "RTE_extended_020" })
public void RTE_020_YoutubeTag_Preview() {
    WikiBasePageObject base = new WikiBasePageObject();
    String articleName = PageContent.ARTICLE_NAME_PREFIX + base.getTimeStamp();
    ArticlePageObject article = new ArticlePageObject().open(articleName);
    SourceEditModePageObject source = article.openCurrectArticleSourceMode();
    YoutubeVideo video = YoutubeVideoProvider.getLatestVideoForQuery("water");
    String videoID = video.getID();
    source.addContentInSourceMode("<youtube>\n" + videoID + "\n</youtube>");
    PreviewEditModePageObject preview = source.previewArticle();
    preview.verifyVideoOnPreview(videoID);
}
Also used : ArticlePageObject(com.wikia.webdriver.pageobjectsfactory.pageobject.article.ArticlePageObject) SourceEditModePageObject(com.wikia.webdriver.pageobjectsfactory.pageobject.article.editmode.SourceEditModePageObject) WikiBasePageObject(com.wikia.webdriver.pageobjectsfactory.pageobject.WikiBasePageObject) YoutubeVideo(com.wikia.webdriver.common.core.video.YoutubeVideo) PreviewEditModePageObject(com.wikia.webdriver.pageobjectsfactory.pageobject.article.editmode.PreviewEditModePageObject) CreationTicket(com.wikia.webdriver.common.core.annotations.CreationTicket) Test(org.testng.annotations.Test)

Example 3 with CreationTicket

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

the class ModalTests method ModalTests_verifyScrollbarAppears.

@CreationTicket(ticketID = "CONCF-621")
@Test(groups = { "ModalTests_verifyScrollbarAppears_001", "ModalTests" }, dataProvider = "DimensionDataProvider")
@Execute(asUser = User.USER)
public void ModalTests_verifyScrollbarAppears(Dimension dimension) {
    String errorMessage = "can not scroll window";
    ArticlePageObject article = new ArticlePageObject().open();
    VisualEditModePageObject visualEditMode = article.navigateToArticleEditPage();
    GalleryBuilderComponentObject galleryBuilder = visualEditMode.clickGalleryButton();
    // resize window
    driver.manage().window().setSize(dimension);
    // make sure you can scroll to finish button and the finish button is visible
    Assertion.assertTrue(galleryBuilder.isFinishButtonVisibleOnPage(), errorMessage);
}
Also used : ArticlePageObject(com.wikia.webdriver.pageobjectsfactory.pageobject.article.ArticlePageObject) GalleryBuilderComponentObject(com.wikia.webdriver.pageobjectsfactory.componentobject.gallery.GalleryBuilderComponentObject) VisualEditModePageObject(com.wikia.webdriver.pageobjectsfactory.pageobject.article.editmode.VisualEditModePageObject) CreationTicket(com.wikia.webdriver.common.core.annotations.CreationTicket) Execute(com.wikia.webdriver.common.core.annotations.Execute) Test(org.testng.annotations.Test)

Aggregations

CreationTicket (com.wikia.webdriver.common.core.annotations.CreationTicket)3 ArticlePageObject (com.wikia.webdriver.pageobjectsfactory.pageobject.article.ArticlePageObject)3 Test (org.testng.annotations.Test)3 YoutubeVideo (com.wikia.webdriver.common.core.video.YoutubeVideo)2 WikiBasePageObject (com.wikia.webdriver.pageobjectsfactory.pageobject.WikiBasePageObject)2 SourceEditModePageObject (com.wikia.webdriver.pageobjectsfactory.pageobject.article.editmode.SourceEditModePageObject)2 Execute (com.wikia.webdriver.common.core.annotations.Execute)1 GalleryBuilderComponentObject (com.wikia.webdriver.pageobjectsfactory.componentobject.gallery.GalleryBuilderComponentObject)1 PreviewEditModePageObject (com.wikia.webdriver.pageobjectsfactory.pageobject.article.editmode.PreviewEditModePageObject)1 VisualEditModePageObject (com.wikia.webdriver.pageobjectsfactory.pageobject.article.editmode.VisualEditModePageObject)1