use of com.wikia.webdriver.pageobjectsfactory.pageobject.wikipage.blog.BlogPageObject in project selenium-tests by Wikia.
the class BlogTests method BlogTests_002_addByUrl.
@Test(dataProviderClass = ArticleDataProvider.class, dataProvider = "articleTitles", groups = { "BlogTests_002", "BlogTests" })
@Execute(asUser = User.USER)
public void BlogTests_002_addByUrl(String blogTitle) {
WikiBasePageObject base = new WikiBasePageObject();
String blogContent = PageContent.BLOG_CONTENT + base.getTimeStamp();
String randomBlogTitle = blogTitle + base.getTimeStamp();
SpecialCreatePage createBlogPage = base.openSpecialCreateBlogPage(wikiURL);
VisualEditModePageObject visualEditMode = createBlogPage.populateTitleField(randomBlogTitle);
visualEditMode.addContent(blogContent);
BlogPageObject blogPage = visualEditMode.submitBlog();
blogPage.verifyBlogTitle(randomBlogTitle);
blogPage.verifyContent(blogContent);
}
use of com.wikia.webdriver.pageobjectsfactory.pageobject.wikipage.blog.BlogPageObject in project selenium-tests by Wikia.
the class BlogTests method BlogTests_005_move.
@Test(groups = { "BlogTests_005", "BlogTests" })
public void BlogTests_005_move() {
WikiBasePageObject base = new WikiBasePageObject();
base.loginAs(credentials.userNameStaff, credentials.passwordStaff, wikiURL);
String blogTitleMove = PageContent.BLOG_POST_NAME_PREFIX + base.getTimeStamp();
UserProfilePageObject userProfile = base.openProfilePage(credentials.userName, wikiURL);
userProfile.clickOnBlogTab();
BlogPageObject blogPage = userProfile.openFirstPost();
RenamePageObject renamePage = blogPage.renameUsingDropdown();
renamePage.rename(credentials.userNameStaff + "/" + blogTitleMove, true);
blogPage.verifyBlogTitle(blogTitleMove);
List<Notification> confirmNotifications = blogPage.getNotifications(NotificationType.CONFIRM);
Assertion.assertEquals(confirmNotifications.size(), 1, RenamePageObject.AssertionMessages.INVALID_NUMBER_OF_CONFIRMING_NOTIFICATIONS);
Assertion.assertTrue(confirmNotifications.stream().findFirst().get().isVisible(), RenamePageObject.AssertionMessages.BANNER_NOTIFICATION_NOT_VISIBLE);
}
use of com.wikia.webdriver.pageobjectsfactory.pageobject.wikipage.blog.BlogPageObject in project selenium-tests by Wikia.
the class BlogTests method BlogTests_001_addFromProfile.
@Test(groups = { "BlogTests_001", "BlogTests", "Smoke1" })
public void BlogTests_001_addFromProfile() {
WikiBasePageObject base = new WikiBasePageObject();
base.loginAs(credentials.userName4, credentials.password4, wikiURL);
String blogTitle = PageContent.BLOG_POST_NAME_PREFIX + base.getTimeStamp();
String blogContent = PageContent.BLOG_CONTENT + base.getTimeStamp();
UserProfilePageObject userProfile = base.openProfilePage(credentials.userName4, wikiURL);
userProfile.clickOnBlogTab();
SpecialCreatePage createBlogPage = userProfile.clickOnCreateBlogPost();
VisualEditModePageObject visualEditMode = createBlogPage.populateTitleField(blogTitle);
visualEditMode.addContent(blogContent);
BlogPageObject blogPage = visualEditMode.submitBlog();
blogPage.verifyBlogTitle(blogTitle);
blogPage.verifyContent(blogContent);
}
use of com.wikia.webdriver.pageobjectsfactory.pageobject.wikipage.blog.BlogPageObject in project selenium-tests by Wikia.
the class BlogFeaturesTests method addingImage.
@Test(groups = { "BlogFeatures_005", "BlogFeaturesTests" })
@Execute(asUser = User.USER)
public void addingImage() {
WikiBasePageObject base = new WikiBasePageObject();
SpecialCreatePage createPage = base.openSpecialCreateBlogPage(wikiURL);
String blogPostTitle = PageContent.BLOG_POST_NAME_PREFIX + createPage.getTimeStamp();
VisualEditModePageObject blogEdit = createPage.populateTitleField(blogPostTitle);
PhotoAddComponentObject photoAddPhoto = blogEdit.clickPhotoButton();
PhotoOptionsComponentObject photoOptions = photoAddPhoto.addPhotoFromWiki("image", 1);
photoOptions.setCaption(PageContent.CAPTION);
photoOptions.clickAddPhoto();
blogEdit.verifyPhoto();
BlogPageObject blogPage = blogEdit.submitBlog();
blogPage.verifyPhoto();
}
use of com.wikia.webdriver.pageobjectsfactory.pageobject.wikipage.blog.BlogPageObject 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();
}
Aggregations