use of com.wikia.webdriver.pageobjectsfactory.componentobject.minieditor.MiniEditorComponentObject in project selenium-tests by Wikia.
the class ArticleCommentsTests method ArticleComments_002_replyComment.
@Test(groups = "ArticleComments_002")
@Execute(asUser = User.COMMENTS_REGULAR_USER)
public void ArticleComments_002_replyComment() {
new ArticleContent().push(PageContent.ARTICLE_TEXT);
ArticlePageObject article = new ArticlePageObject().open();
String comment = PageContent.COMMENT_TEXT + DateTime.now().getMillis();
MiniEditorComponentObject editor = article.triggerCommentArea();
editor.switchAndWrite(comment);
article.submitComment();
article.verifyCommentText(comment);
article.verifyCommentCreator(User.COMMENTS_REGULAR_USER.getUserName());
article.triggerCommentReply();
String commentReply = PageContent.REPLY_TEXT + article.getTimeStamp();
editor.switchAndReplyComment(commentReply);
article.submitReplyComment();
article.verifyCommentReply(commentReply);
article.verifyReplyCreator(User.COMMENTS_REGULAR_USER.getUserName());
}
use of com.wikia.webdriver.pageobjectsfactory.componentobject.minieditor.MiniEditorComponentObject in project selenium-tests by Wikia.
the class BlogCommentsTests method BlogComments_003_User_editComment.
@Test(groups = "BlogComments_003")
@Execute(asUser = User.USER)
public void BlogComments_003_User_editComment() {
WikiBasePageObject base = new WikiBasePageObject();
UserProfilePageObject userProfile = base.openProfilePage(credentials.userName, wikiURL);
userProfile.clickOnBlogTab();
BlogPageObject blogPage = userProfile.openFirstPost();
MiniEditorComponentObject editor = blogPage.triggerCommentArea();
String comment = PageContent.COMMENT_TEXT + blogPage.getTimeStamp();
editor.switchAndWrite(comment);
blogPage.submitComment();
blogPage.verifyCommentText(comment);
blogPage.verifyCommentCreator(credentials.userName);
blogPage.triggerEditCommentArea();
String commentEdited = PageContent.COMMENT_TEXT + blogPage.getTimeStamp();
editor.switchAndEditComment(commentEdited);
blogPage.submitEditComment();
blogPage.verifyCommentText(commentEdited);
}
use of com.wikia.webdriver.pageobjectsfactory.componentobject.minieditor.MiniEditorComponentObject in project selenium-tests by Wikia.
the class VetAddingVideoTests method VetAddVideo_002_MessageWallLibrary.
@Test(groups = { "VetAddVideo_002" })
@RelatedIssue(issueID = "QAART-889")
@Execute(asUser = User.USER)
public void VetAddVideo_002_MessageWallLibrary() {
MessageWall wall = new MessageWall(driver).open(credentials.userName);
String message = PageContent.MESSAGE_WALL_MESSAGE_PREFIX + wall.getTimeStamp();
String title = PageContent.MESSAGE_WALL_TITLE_PREFIX + wall.getTimeStamp();
MiniEditorComponentObject mini = wall.triggerMessageArea();
wall.clickBoldButton();
mini.switchAndWrite(message);
wall.setTitle(title);
VetAddVideoComponentObject vetAddingVideo = mini.clickAddVideo();
VetOptionsComponentObject vetOptions = vetAddingVideo.addVideoByQuery(VideoContent.WIKIA_VIDEO_QUERY, 0);
vetOptions.setCaption(PageContent.CAPTION);
vetOptions.submit();
mini.verifyVideoMiniEditor();
wall.submit();
wall.verifyPostedMessageVideo(title);
}
use of com.wikia.webdriver.pageobjectsfactory.componentobject.minieditor.MiniEditorComponentObject in project selenium-tests by Wikia.
the class VetArticleCommentsTests method RegularUserCanAddVideoInArticleCommentEditorByProvidingYoutubeVideoUrl.
@Test(groups = { "VetArticleComments_001" })
@Execute(asUser = User.USER)
@RelatedIssue(issueID = "SUS-758", comment = "This issue is related to API call and should not cause permanent " + "test failure. Otherwise the failure must be caused by other issue")
public void RegularUserCanAddVideoInArticleCommentEditorByProvidingYoutubeVideoUrl() {
new ArticleContent().clear();
ArticlePageObject article = new ArticlePageObject().open();
MiniEditorComponentObject editor = article.triggerCommentArea();
VetAddVideoComponentObject vetAddingVideo = editor.clickAddVideo();
YoutubeVideo video = YoutubeVideoProvider.getLatestVideoForQuery("microsoft");
String expectedCaption = PageContent.CAPTION + article.getTimeStamp();
vetAddingVideo.addVideoByUrl(video.getUrl()).setCaption(expectedCaption).submit();
Assertion.assertTrue(article.getArticleComment().isVideoVisible());
article.submitComment();
Assertion.assertEquals(article.getArticleComment().getLatestCommentCaption(), expectedCaption, "Latest comment caption doesn't equal to expected caption");
}
use of com.wikia.webdriver.pageobjectsfactory.componentobject.minieditor.MiniEditorComponentObject in project selenium-tests by Wikia.
the class MessageWallFeaturesTests method userCanWriteMessageInItallic.
@Test(groups = { "MessageWallFeatures_003", "MessageWallFeatures", "MessageWallTests" })
@Execute(asUser = User.USER_MESSAGE_WALL)
public void userCanWriteMessageInItallic() {
MessageWall wall = new MessageWall(driver).open(User.USER_MESSAGE_WALL.getUserName());
String message = PageContent.MESSAGE_WALL_MESSAGE_PREFIX + wall.getTimeStamp();
String title = PageContent.MESSAGE_WALL_TITLE_PREFIX + wall.getTimeStamp();
wall.setTitle(title);
MiniEditorComponentObject mini = wall.triggerMessageArea();
wall.clickItalicButton();
mini.switchAndWrite(message);
wall.submit();
wall.verifyMessageItalicText(title, message, User.USER_MESSAGE_WALL.getUserName());
}
Aggregations