use of com.wikia.webdriver.elements.mercury.components.discussions.common.Post in project selenium-tests by Wikia.
the class UpvotingTests method postListUpvoteButtonClickDoesntAddAnUpvote.
private void postListUpvoteButtonClickDoesntAddAnUpvote() {
Post post = findPosts();
int replyIndex = 0;
post.isUpvoteButtonVisible(replyIndex);
String firstVoteCount = post.getVoteCount(replyIndex);
post.clickUpvoteButton(replyIndex);
post.waitForVoteCountChangeTimeLagToPass();
String secondVoteCount = post.getVoteCount(replyIndex);
Assertion.assertEquals(firstVoteCount, secondVoteCount);
}
use of com.wikia.webdriver.elements.mercury.components.discussions.common.Post in project selenium-tests by Wikia.
the class UpvotingTests method postListUpvoteButtonClickAddsAnUpvoteAndSecondClickRemovesTheUpvote.
/**
* TESTING METHODS SECTION
*/
private void postListUpvoteButtonClickAddsAnUpvoteAndSecondClickRemovesTheUpvote() {
Post post = findPosts();
int postIndex = 0;
post.isUpvoteButtonVisible(postIndex);
String firstVoteCount = post.getVoteCount(postIndex);
post.clickUpvoteButton(postIndex);
post.waitForVoteCountToChange(postIndex, firstVoteCount);
String secondVoteCount = post.getVoteCount(postIndex);
Assertion.assertNotEquals(firstVoteCount, secondVoteCount);
post.clickUpvoteButton(postIndex);
post.waitForVoteCountToChange(postIndex, secondVoteCount);
String thirdVoteCount = post.getVoteCount(postIndex);
Assertion.assertEquals(firstVoteCount, thirdVoteCount);
}
use of com.wikia.webdriver.elements.mercury.components.discussions.common.Post in project selenium-tests by Wikia.
the class LayoutTests method postsListLoads.
private void postsListLoads() {
Post post = new PostsListPage().open().getPost();
Assertion.assertFalse(post.isPostListEmpty());
}
use of com.wikia.webdriver.elements.mercury.components.discussions.common.Post in project selenium-tests by Wikia.
the class DeleteAllPostsByUserTests method cancelAndReturnFirst.
private PostEntity cancelAndReturnFirst() {
String postId = setUp().getId();
getDeleteAllButton(userWithPosts.getUserId()).click().cancelAndWait();
return new Post().findPostById(postId);
}
use of com.wikia.webdriver.elements.mercury.components.discussions.common.Post in project selenium-tests by Wikia.
the class DeleteAllPostsByUserTests method deleteAllAndReturnFirst.
private PostEntity deleteAllAndReturnFirst() {
String postId = setUp().getId();
getDeleteAllButton(userWithPosts.getUserId()).click().confirmAndWait();
return new Post().findPostById(postId);
}
Aggregations