use of com.wikia.webdriver.common.core.annotations.InBrowser in project selenium-tests by Wikia.
the class LockingPostTests method discussionsAdministratorOnDesktopCanUnlockPostLockedByDiscussionsAdministratorOnPostDetailsPage.
@Test(groups = { "discussions-locking-posts-desktop", "discussions-discussionsAdministratorDesktopLocking" })
@Execute(asUser = User.DISCUSSIONS_ADMINISTRATOR)
@InBrowser(browser = Browser.FIREFOX, browserSize = DESKTOP_RESOLUTION)
public void discussionsAdministratorOnDesktopCanUnlockPostLockedByDiscussionsAdministratorOnPostDetailsPage() {
PostEntity postEntity = unlockPostLockedByDiscussionsAdministrator();
final String name = User.DISCUSSIONS_ADMINISTRATOR.name();
Assertion.assertFalse(postEntity.isLocked(), String.format(SHOULD_UNLOCK_MESSAGE, name, name));
}
use of com.wikia.webdriver.common.core.annotations.InBrowser in project selenium-tests by Wikia.
the class LockingPostTests method discussionsModeratorOnMobileCanUnlockPostLockedByDiscussionsModeratorOnPostDetailsPage.
@Test(groups = { "discussions-locking-posts-mobile", "discussions-discussionsModeratorMobileLocking" })
@Execute(asUser = User.DISCUSSIONS_MODERATOR)
@InBrowser(browser = Browser.CHROME, emulator = Emulator.GOOGLE_NEXUS_5)
public void discussionsModeratorOnMobileCanUnlockPostLockedByDiscussionsModeratorOnPostDetailsPage() {
PostEntity postEntity = unlockPostLockedByDiscussionsModerator();
final String name = User.DISCUSSIONS_MODERATOR.name();
Assertion.assertFalse(postEntity.isLocked(), String.format(SHOULD_UNLOCK_MESSAGE, name, name));
}
use of com.wikia.webdriver.common.core.annotations.InBrowser in project selenium-tests by Wikia.
the class LockingPostTests method discussionsModeratorOnDesktopCanAddReplyUnderUnlockedPostOnPostDetailsPage.
@Test(groups = { "discussions-locking-posts-desktop", "discussions-discussionsModeratorDesktopLocking" })
@Execute(asUser = User.DISCUSSIONS_MODERATOR)
@InBrowser(browser = Browser.FIREFOX, browserSize = DESKTOP_RESOLUTION)
public void discussionsModeratorOnDesktopCanAddReplyUnderUnlockedPostOnPostDetailsPage() {
final PostDetailsPage page = openPageWithPostUnlockedByStaff();
final String text = addReplyOnDesktop(page);
final boolean actual = isReplyNotPresent(page, text);
final String message = String.format(SHOULD_ADD_REPLY_MESSAGE, User.DISCUSSIONS_MODERATOR.name(), User.STAFF.name());
Assertion.assertFalse(actual, message);
}
use of com.wikia.webdriver.common.core.annotations.InBrowser in project selenium-tests by Wikia.
the class EditingPostTests method userOnMobileCanNotSeeThatPostWasEditedByAuthorOnPostDetailsPage.
@Test(groups = USER_MOBILE_TEST_GROUP)
@Execute(asUser = User.USER)
@InBrowser(browser = Browser.CHROME, emulator = Emulator.GOOGLE_NEXUS_5)
public void userOnMobileCanNotSeeThatPostWasEditedByAuthorOnPostDetailsPage() {
final PostEntity.Data data = updatePostAsStaffRemotely(createPostAsStaffRemotely());
final PostEntity post = new PostDetailsPage().open(data.getId()).getPost().findNewestPost();
Assertion.assertFalse(post.hasEditedBySection(), SAME_PERSON_MESSAGE);
}
use of com.wikia.webdriver.common.core.annotations.InBrowser in project selenium-tests by Wikia.
the class EditingPostTests method discussionsAdministratorOnMobileCanSeeThatPostWasEditedByAdministratorOnPostDetailsPage.
// Discussions Administrator on mobile
@Test(groups = DISCUSSIONS_ADMINISTRATOR_MOBILE_TEST_GROUP)
@Execute(asUser = User.DISCUSSIONS_ADMINISTRATOR)
@InBrowser(browser = Browser.CHROME, emulator = Emulator.GOOGLE_NEXUS_5)
public void discussionsAdministratorOnMobileCanSeeThatPostWasEditedByAdministratorOnPostDetailsPage() {
final PostEntity.Data data = updatePostAsStaffRemotely(createPostAsUserRemotely());
final PostEntity post = new PostDetailsPage().open(data.getId()).getPost().findPostById(data.getId());
Assertion.assertTrue(post.hasEditedBySection(), SHOULD_HAVE_EDITED_BY_SECTION_MESSAGE);
Assertion.assertEquals(post.getEditedBySectionText(), EDITED_BY_QA_STAFF, SHOULD_HAVE_DETAILED_INFORMATION_MESSAGE);
}
Aggregations