use of com.wikia.webdriver.common.core.annotations.InBrowser in project selenium-tests by Wikia.
the class CategoriesTests method discussionsAdministratorOnMobileCanNotEditGeneralCategory.
// Discussions Administrator on mobile
@Test(groups = { MOBILE })
@Execute(asUser = User.DISCUSSIONS_ADMINISTRATOR, onWikia = MercuryWikis.DISCUSSIONS_MOBILE)
@InBrowser(browser = Browser.CHROME, emulator = Emulator.GOOGLE_NEXUS_5)
public void discussionsAdministratorOnMobileCanNotEditGeneralCategory() {
CategoryPill.Data postCategory = setUp(MercuryWikis.DISCUSSIONS_MOBILE);
final PostsListPage page = new PostsListPage().open(siteId);
final CategoriesFieldset categoriesFieldset = page.getFiltersPopOver().click().getCategoriesFieldset();
try {
assertTrue(categoriesFieldset.canEdit(), SHOULD_EDIT_CATEGORIES_MESSAGE);
assertFalse(categoriesFieldset.clickEdit().canEditGeneralCategory(), GENERAL_CATEGORY_SHOULD_BE_NOT_EDITABLE_MESSAGE);
} finally {
cleanUp(postCategory);
}
}
use of com.wikia.webdriver.common.core.annotations.InBrowser in project selenium-tests by Wikia.
the class CreatingPostTests method userOnMobileCannotSavePostWithoutCategoryAndDescription.
/*
* LOGGED-IN USERS ON MOBILE SECTION
*/
@Test(groups = MOBILE)
@Execute(asUser = User.USER, onWikia = MercuryWikis.DISCUSSIONS_2)
@InBrowser(browser = Browser.CHROME, emulator = Emulator.GOOGLE_NEXUS_5)
public void userOnMobileCannotSavePostWithoutCategoryAndDescription() {
PostsListPage page = new PostsListPage().open();
PostsCreator postsCreator = page.getPostsCreatorMobile();
assertThatPostWithoutSelectedCategoryAndDescriptionCannotBeAdded(postsCreator);
}
use of com.wikia.webdriver.common.core.annotations.InBrowser in project selenium-tests by Wikia.
the class CreatingPostTests method userOnDesktopCannotAddPostWithoutTitle.
@Test(groups = DESKTOP)
@Execute(asUser = User.USER)
@InBrowser(browser = Browser.FIREFOX, browserSize = DESKTOP_RESOLUTION)
public void userOnDesktopCannotAddPostWithoutTitle() throws MalformedURLException {
String description = TextGenerator.createUniqueText();
PostsListPage page = new PostsListPage().open();
PostsCreator postsCreator = page.getPostsCreatorDesktop();
fillPostCategoryWith(postsCreator, description);
Assertion.assertFalse(postsCreator.isPostButtonActive());
}
use of com.wikia.webdriver.common.core.annotations.InBrowser in project selenium-tests by Wikia.
the class CreatingPostTests method anonUserOnDesktopWhenScrollsDownThenSeesStickyEditor.
@Test(groups = DESKTOP)
@Execute(asUser = User.ANONYMOUS, onWikia = MercuryWikis.DISCUSSIONS_1)
@InBrowser(browser = Browser.FIREFOX, browserSize = DESKTOP_RESOLUTION)
public void anonUserOnDesktopWhenScrollsDownThenSeesStickyEditor() {
PostsListPage postsListPage = new PostsListPage().open();
postsListPage.getPost().scrollToLoadMoreButton();
PostsCreatorDesktop postsCreator = postsListPage.getPostsCreatorDesktop();
Assertion.assertFalse(postsCreator.isExpanded());
Assertion.assertTrue(postsCreator.isSticky());
}
use of com.wikia.webdriver.common.core.annotations.InBrowser in project selenium-tests by Wikia.
the class CreatingReplyTests method userOnDesktopShouldFollowPostWhenAddedReplyOnPostDetailsPage.
@Test(groups = DESKTOP)
@Execute(asUser = User.USER_2)
@InBrowser(browser = Browser.FIREFOX, browserSize = DESKTOP_RESOLUTION)
public void userOnDesktopShouldFollowPostWhenAddedReplyOnPostDetailsPage() {
final PostDetailsPage page = new PostDetailsPage().open(createPostAsUserRemotely().getId());
final ReplyCreator replyCreator = page.getReplyCreatorDesktop();
assertThatPostIsFollowedWhenReplyAdded(page, replyCreator);
assertThatPostCanBeUnfollowed(page);
}
Aggregations