use of com.wikia.webdriver.pageobjectsfactory.componentobject.photo.PhotoAddComponentObject in project selenium-tests by Wikia.
the class ArticleFeaturesCRUDTestsUser method addingImagePlaceholder.
@Test(groups = { "ArticleFeaturesCRUDUser_014" })
@Execute(asUser = User.USER)
public void addingImagePlaceholder() {
new ArticleContent().clear();
new ArticlePageObject().open();
VisualEditModePageObject visualEditMode = new WikiBasePageObject().goToArticleDefaultContentEditPage(wikiURL, TestContext.getCurrentMethodName());
ArticlePageObject article = visualEditMode.submitArticle();
PhotoAddComponentObject photoAddPhoto = article.clickAddImagePlaceholder();
PhotoOptionsComponentObject photoOptions = photoAddPhoto.addPhotoFromWiki("image", 2);
photoOptions.setCaption(PageContent.CAPTION);
photoOptions.clickAddPhoto();
article.verifyPhoto();
}
use of com.wikia.webdriver.pageobjectsfactory.componentobject.photo.PhotoAddComponentObject in project selenium-tests by Wikia.
the class LightboxTests method LightboxTest_005_verifyExistenceAndURLsOfSocialButtons.
@Test(groups = "LightboxTest_005")
@Execute(asUser = User.STAFF)
@InBrowser(browser = Browser.FIREFOX, browserSize = BROWSER_SIZE)
public void LightboxTest_005_verifyExistenceAndURLsOfSocialButtons() {
new ArticleContent().push(PageContent.ARTICLE_TEXT);
ArticlePageObject article = new ArticlePageObject().open();
VisualEditModePageObject visualEditMode = article.navigateToArticleEditPage();
visualEditMode.clearContent();
PhotoAddComponentObject photoAddPhoto = visualEditMode.clickPhotoButton();
PhotoOptionsComponentObject photoOptions = photoAddPhoto.addPhotoFromWiki("image", 1);
photoOptions.setCaption(PageContent.CAPTION);
photoOptions.clickAddPhoto();
visualEditMode.verifyPhoto();
visualEditMode.submitArticle();
article.verifyPhoto();
LightboxComponentObject lightbox = article.clickThumbnailImage();
lightbox.clickPinButton();
// Assure header buttons are visible if not hovered over
lightbox.makeHeaderVisible();
lightbox.clickShareButton();
lightbox.verifyShareButtons();
lightbox.clickFacebookShareButton();
lightbox.verifyUrlInNewWindow(URLsContent.FACEBOOK_DOMAIN);
lightbox.clickTwitterShareButton();
lightbox.verifyUrlInNewWindow(URLsContent.TWITTER_DOMAIN);
lightbox.clickStumbleUponShareButton();
lightbox.verifyUrlInNewWindow(URLsContent.STUMPLEUPON_DOMAIN);
lightbox.clickRedditShareButton();
lightbox.verifyUrlInNewWindow(URLsContent.REDDIT_DOMAIN);
lightbox.clickPlusOneShareButton();
lightbox.verifyUrlInNewWindow(URLsContent.GOOGLE_DOMAIN);
lightbox.clickCloseShareScreenButton();
lightbox.verifyShareScreenClosed();
lightbox.clickCloseButton();
lightbox.verifyLightboxClosed();
}
use of com.wikia.webdriver.pageobjectsfactory.componentobject.photo.PhotoAddComponentObject in project selenium-tests by Wikia.
the class MessageWallFeaturesTests method userCanWriteMessageWithImage.
@Test(groups = { "MessageWallFeatures_004", "MessageWallFeatures", "MessageWallTests" })
@Execute(asUser = User.USER_MESSAGE_WALL)
public void userCanWriteMessageWithImage() {
MessageWall wall = new MessageWall(driver).open(User.USER_MESSAGE_WALL.getUserName());
String title = PageContent.MESSAGE_WALL_TITLE_PREFIX + wall.getTimeStamp();
wall.setTitle(title);
wall.triggerMessageArea();
PhotoAddComponentObject photoAddPhoto = wall.clickImageButton();
PhotoOptionsComponentObject photoOptions = photoAddPhoto.addPhotoFromWiki("image", 1);
photoOptions.setCaption(PageContent.CAPTION);
photoOptions.clickAddPhoto();
wall.submit();
wall.verifyImageAdded(title);
}
use of com.wikia.webdriver.pageobjectsfactory.componentobject.photo.PhotoAddComponentObject in project selenium-tests by Wikia.
the class ForumBoardPage method startDiscussionWithImage.
public void startDiscussionWithImage(String title) {
wait.forElementVisible(discussionTitleArea);
jsActions.focus(discussionTitleArea);
discussionTitleArea.sendKeys(title);
wait.forElementVisible(wikiaEditorTextArea);
jsActions.focus(wikiaEditorTextArea);
PhotoAddComponentObject photoAdd = miniEditor.clickAddImage();
PhotoOptionsComponentObject photoOptions = photoAdd.addPhotoFromWiki("image", 1);
photoOptions.clickAddPhoto();
PageObjectLogging.log("startDiscussionWithImage", "discussion with image started" + title, true, driver);
}
use of com.wikia.webdriver.pageobjectsfactory.componentobject.photo.PhotoAddComponentObject in project selenium-tests by Wikia.
the class ForcedLoginTests method anonCanLogInViaAuthModalWhenAddingPhoto.
@Test(groups = "ForcedLogin_anonCanLogInViaAuthModalWhenAddingPhoto")
public void anonCanLogInViaAuthModalWhenAddingPhoto() {
WikiBasePageObject base = new WikiBasePageObject();
String articleName = PageContent.ARTICLE_NAME_PREFIX + base.getTimeStamp();
VisualEditModePageObject edit = base.navigateToArticleEditPage(wikiURL, articleName);
edit.clickPhotoButton();
DetachedSignInPage authModal = new DetachedRegisterPage().navigateToSignIn();
authModal.login(credentials.userName10, credentials.password10);
edit.verifyUserLoggedIn(credentials.userName10);
assertTrue(edit.isStringInURL(articleName));
assertTrue(edit.isStringInURL(URLsContent.ACTION_EDIT));
PhotoAddComponentObject addPhoto = edit.clickPhotoButton();
addPhoto.verifyAddPhotoModal();
}
Aggregations