use of com.wikia.webdriver.elements.mercury.pages.discussions.UserPostsPage in project selenium-tests by Wikia.
the class ReportingPostTests method userCannotReReportPostOnUserPostPage.
private void userCannotReReportPostOnUserPostPage() {
final PostEntity.Data data = createAndReportPostRemotelyAsFirstUser();
validatePostRemotelyAsDiscussionsModerator(data);
final UserPostsPage userPostsPage = openUserPostsAndWaitUntilLoaded(data.getAuthorId());
final PostEntity postEntity = userPostsPage.getPost().findPostById(data.getId());
assertFalse(postEntity.isReported(), NO_REPORTED_INDICATOR_ON_POST_MESSAGE);
assertFalse(isReportPostOptionAvailableFor(postEntity), NO_REPORT_POST_OPTION_MESSAGE);
}
use of com.wikia.webdriver.elements.mercury.pages.discussions.UserPostsPage in project selenium-tests by Wikia.
the class ReportingPostTests method anonUserOnDesktopCanNotReportPostOnUserPostsPage.
@Test(groups = "discussions-anonUserDesktopReporting")
@Execute(asUser = User.ANONYMOUS)
@InBrowser(browser = Browser.FIREFOX, browserSize = DESKTOP_RESOLUTION)
public void anonUserOnDesktopCanNotReportPostOnUserPostsPage() {
final UserPostsPage page = openDefaultUserPostPageWaiting();
assertFalse(isReportPostOptionAvailableOn(page), NO_REPORT_POST_OPTION_MESSAGE);
}
use of com.wikia.webdriver.elements.mercury.pages.discussions.UserPostsPage in project selenium-tests by Wikia.
the class LockingPostTests method findMoreOptionsOnUserPostsPage.
private MoreOptionsPopOver findMoreOptionsOnUserPostsPage() {
final PostEntity.Data data = DiscussionsOperations.using(User.USER, driver).createPostWithUniqueData();
final PageWithPosts page = new UserPostsPage().open(data.getAuthorId());
return findMoreOptions(page, data);
}
use of com.wikia.webdriver.elements.mercury.pages.discussions.UserPostsPage in project selenium-tests by Wikia.
the class ZeroErrorStateTests method userOnDesktopSeesProperMessageWhenOpensNonExistingUserPostsPage.
/**
* TESTING METHODS SECTION
*/
private void userOnDesktopSeesProperMessageWhenOpensNonExistingUserPostsPage() {
ErrorMessages errorMessage = new UserPostsPage().open().getErrorMessages();
Assertion.assertTrue(errorMessage.isErrorMessagePresent());
Assertion.assertEquals(errorMessage.getErrorMessageText(), MESSAGE_1 + MESSAGE_2);
}
use of com.wikia.webdriver.elements.mercury.pages.discussions.UserPostsPage in project selenium-tests by Wikia.
the class ReportingPostTests method anonUserOnDesktopCanNotSeeDeletedPostOnUserPostsPage.
@Test(groups = "discussions-anonUserDesktopReporting")
@Execute(asUser = User.ANONYMOUS)
@InBrowser(browser = Browser.FIREFOX, browserSize = DESKTOP_RESOLUTION)
public void anonUserOnDesktopCanNotSeeDeletedPostOnUserPostsPage() {
final PostEntity.Data data = createAndReportAndDeletePostRemotely();
UserPostsPage page = openUserPostsAndWaitUntilLoaded(data.getAuthorId());
PostEntity post = page.getPost().findPostById(data.getId());
assertNull(post, ANON_NOT_VISIBLE_DELETED_POST_MESSAGE);
}
Aggregations