use of com.wikia.webdriver.pageobjectsfactory.componentobject.vet.VetAddVideoComponentObject in project selenium-tests by Wikia.
the class VetModalCaptionTests method VetModalCaption_005_videoNameNotEditable.
@Test(groups = { "VetModalCaption_005" })
@Execute(asUser = User.USER)
public void VetModalCaption_005_videoNameNotEditable() {
WikiBasePageObject base = new WikiBasePageObject();
articleTitleNotEditable = PageContent.ARTICLE_NAME_PREFIX + base.getTimeStamp();
VisualEditModePageObject visualEditMode = base.navigateToArticleEditPage(wikiURL, articleTitleNotEditable);
VetAddVideoComponentObject vetAddingVideo = visualEditMode.clickVideoButton();
VetOptionsComponentObject vetOptions = vetAddingVideo.addVideoByQuery(VideoContent.WIKIA_VIDEO_QUERY, 1);
vetOptions.verifyNameNotEditable();
}
use of com.wikia.webdriver.pageobjectsfactory.componentobject.vet.VetAddVideoComponentObject in project selenium-tests by Wikia.
the class VetModalWidthTests method Vet_Modal_001_modalWidth.
@Test(groups = { "VetModalwidth_001" })
@Execute(asUser = User.USER)
public void Vet_Modal_001_modalWidth() {
WikiBasePageObject base = new WikiBasePageObject();
articleTitle = PageContent.ARTICLE_NAME_PREFIX + base.getTimeStamp();
VisualEditModePageObject visualEditMode = base.navigateToArticleEditPage(wikiURL, articleTitle);
VetAddVideoComponentObject vetAddingVideo = visualEditMode.clickVideoButton();
VetOptionsComponentObject vetOptions = vetAddingVideo.addVideoByUrl(VideoContent.YOUTUBE_VIDEO_URL);
vetOptions.adjustWith(MODAL_WIDTH);
vetOptions.submit();
Assertion.assertEquals(visualEditMode.getVideoWidth(), MODAL_WIDTH);
SourceEditModePageObject sourceEditMode = visualEditMode.clickSourceButton();
sourceEditMode.verifySourceModeEnabled();
Assertion.assertEquals(sourceEditMode.getVideoWidth(), MODAL_WIDTH);
PreviewEditModePageObject previewMode = sourceEditMode.previewArticle();
Assertion.assertEquals(previewMode.getVideoWidth(), MODAL_WIDTH);
previewMode.closePreviewModal();
ArticlePageObject article = sourceEditMode.submitArticle();
Assertion.assertEquals(article.getVideoThumbnailWidth(), MODAL_WIDTH);
}
use of com.wikia.webdriver.pageobjectsfactory.componentobject.vet.VetAddVideoComponentObject in project selenium-tests by Wikia.
the class FilePageTests method filePage005_deleteFromHistory.
/**
* Verify that a video can be deleted from the File page
*/
@Test(groups = { "FilePage", "filePage005_deleteFromHistory", "Media" })
@RelatedIssue(issueID = "SUS-317", comment = "Product code defect. Test manually that the video can be deleted")
public void filePage005_deleteFromHistory() {
YoutubeVideo video = YoutubeVideoProvider.getLatestVideoForQuery("pokemon");
// Go to Special:Videos to add a video
SpecialVideosPageObject specialVideos = new SpecialVideosPageObject(driver);
specialVideos.loginAs(credentials.userNameStaff, credentials.passwordStaff, wikiURL);
specialVideos.openSpecialVideoPage(wikiURL);
// Add a Youtube video we'll delete
VetAddVideoComponentObject vetAddingVideo = specialVideos.clickAddAVideo();
vetAddingVideo.addVideoByUrl(video.getUrl());
// Verify the video is actually there
specialVideos.verifyVideoAdded(video.getTitle());
// Go to the history tab and add a second video to test deleting a version
FilePage filePage = new FilePage().open(video.getFileName());
filePage.selectHistoryTab();
filePage.replaceVideo(VideoContent.YOUTUBE_VIDEO_URL5);
// Load the file page again, should have the same name
filePage.open(video.getFileName()).verifyEmbeddedVideoIsPresent();
//Removed following lines until SUS-317 is fixed
//// Go to the history tab and verify there are at least two videos
//filePage.selectHistoryTab();
//filePage.verifyVersionCountAtLeast(2);
//// Delete the second version
//DeletePageObject deletePage = filePage.deleteVersion(2);
//deletePage.submitDeletion();
//Removed above lines until SUS-317is fixed
// Load the file page again, should have the same name
filePage.open(video.getFileName()).verifyEmbeddedVideoIsPresent();
// Delete the first version and thus the whole page
DeletePageObject deletePage = filePage.deleteVersion(1);
deletePage.submitDeletion();
// Go back to the file page and make sure its gone
filePage.open(video.getFileName()).verifyEmptyFilePage();
}
use of com.wikia.webdriver.pageobjectsfactory.componentobject.vet.VetAddVideoComponentObject in project selenium-tests by Wikia.
the class BlogFeaturesTests method BlogFeatures_004_AddingVideo.
@Test(groups = { "BlogFeatures_004", "BlogFeaturesTests", "Media" })
@Execute(asUser = User.USER, onWikia = "mobileregressiontesting")
public void BlogFeatures_004_AddingVideo() {
WikiBasePageObject base = new WikiBasePageObject();
SpecialCreatePage createPage = base.openSpecialCreateBlogPage(wikiURL);
String blogPostTitle = PageContent.BLOG_POST_NAME_PREFIX + createPage.getTimeStamp();
VisualEditModePageObject blogEdit = createPage.populateTitleField(blogPostTitle);
VetAddVideoComponentObject vetAddVideo = blogEdit.clickVideoButton();
VetOptionsComponentObject vetOptions = vetAddVideo.addVideoByUrl(VideoContent.YOUTUBE_VIDEO_URL);
vetOptions.setCaption(PageContent.CAPTION);
vetOptions.submit();
blogEdit.verifyVideo();
BlogPageObject blogPage = blogEdit.submitBlog();
blogPage.verifyVideo();
}
use of com.wikia.webdriver.pageobjectsfactory.componentobject.vet.VetAddVideoComponentObject in project selenium-tests by Wikia.
the class ArticleSourceModeTests method RTE_016_Video.
@Test(groups = { "RTE_extended_3", "RTE_extended_016", "Media" })
public void RTE_016_Video() {
WikiBasePageObject base = new WikiBasePageObject();
String articleName = PageContent.ARTICLE_NAME_PREFIX + base.getTimeStamp();
ArticlePageObject article = new ArticlePageObject().open(articleName);
SourceEditModePageObject source = article.openCurrectArticleSourceMode();
VetAddVideoComponentObject vetAddingVideo = source.clickAddVideo();
VetOptionsComponentObject vetOptions = vetAddingVideo.addVideoByUrl(VideoContent.YOUTUBE_VIDEO_URL);
vetOptions.setCaption(PageContent.CAPTION);
vetOptions.submit();
source.checkSourceVideoContent("[[" + VideoContent.YOUTUBE_VIDEO_WIKITEXT + PageContent.CAPTION + "]]");
}
Aggregations