use of com.wikia.webdriver.pageobjectsfactory.pageobject.visualeditor.VisualEditorPageObject in project selenium-tests by Wikia.
the class VEGalleryTests method VEGalleryTests_003_PreviewOnTitle.
//AG03
@Test(groups = { "VEGallery", "VEGalleryTests_003", "VEGalleryPreview" })
public void VEGalleryTests_003_PreviewOnTitle() {
String randomArticleName = PageContent.ARTICLE_NAME_PREFIX + article.getTimeStamp();
VisualEditorPageObject ve = article.openVEOnArticle(wikiURL, randomArticleName);
ve.verifyVEToolBarPresent();
ve.verifyEditorSurfacePresent();
VisualEditorInsertGalleryDialog galleryDialog = ve.clickGalleryButton();
galleryDialog = galleryDialog.searchMedia("he");
ve = galleryDialog.clickTitleToPreview(7);
ve.verifyPreviewImage();
}
use of com.wikia.webdriver.pageobjectsfactory.pageobject.visualeditor.VisualEditorPageObject in project selenium-tests by Wikia.
the class VEImageTests method changeImageAlignment.
@Test(groups = { "VEImageTests", "VEMediaSetting" })
@Execute(asUser = User.USER_9)
public void changeImageAlignment() {
int numOfMedia = 3;
List<String> wikiTexts = new ArrayList<String>();
wikiTexts.add("|centre");
wikiTexts.add("|left");
String randomArticleName = PageContent.ARTICLE_NAME_PREFIX + new VisualEditorPageObject().getTimeStamp();
VisualEditorPageObject veCreatePage = new VisualEditorPageObject().openVEOnArticle(wikiURL, randomArticleName);
VisualEditorAddMediaDialog mediaDialog = veCreatePage.searchImage("h");
veCreatePage = mediaDialog.addExistingMedia(numOfMedia);
veCreatePage.verifyMedias(numOfMedia);
veCreatePage.clickPublishButton();
new VisualEditorSaveChangesDialog(this.driver).savePage();
veCreatePage.waitForPageLoad();
ArticlePageObject article = new ArticlePageObject();
article.openVEModeWithMainEditButton();
VisualEditorPageObject ve = new VisualEditorPageObject();
ve.alignMedia(2, Alignment.LEFT);
ve.alignMedia(0, Alignment.CENTER);
ve.verifyEditorSurfacePresent();
ve.verifyVEToolBarPresent();
VisualEditorSaveChangesDialog saveDialog = ve.clickPublishButton();
VisualEditorReviewChangesDialog reviewDialog = saveDialog.clickReviewYourChanges();
reviewDialog.verifyAddedDiffs(wikiTexts);
saveDialog = reviewDialog.clickReturnToSaveFormButton();
saveDialog.savePage();
article.verifyVEPublishComplete();
}
use of com.wikia.webdriver.pageobjectsfactory.pageobject.visualeditor.VisualEditorPageObject in project selenium-tests by Wikia.
the class VEImageTests method editImageCaption.
@Test(groups = { "VEImageTests", "VEMediaSetting" })
@Execute(asUser = User.USER_9)
public void editImageCaption() {
String captionText = "test123";
VisualEditorPageObject ve = new VisualEditorPageObject().openVEOnArticle(wikiURL, PageContent.ARTICLE_NAME_PREFIX + DateTime.now().getMillis());
ve.verifyVEToolBarPresent();
ve.verifyEditorSurfacePresent();
VisualEditorAddMediaDialog mediaDialog = ve.clickImageButton();
mediaDialog = mediaDialog.searchMedia("h");
ve = mediaDialog.addExistingMedia(1);
ve.verifyVideos(1);
ve.selectMedia();
VisualEditorMediaSettingsDialog mediaSettingsDialog = ve.openMediaSettings();
mediaSettingsDialog.typeCaption(captionText);
ve = mediaSettingsDialog.clickApplyChangesButton();
ve.verifyVideoCaption(captionText);
ve.publish();
}
use of com.wikia.webdriver.pageobjectsfactory.pageobject.visualeditor.VisualEditorPageObject in project selenium-tests by Wikia.
the class VEImageTests method previewImage.
@Test(groups = { "VEImageTests", "VEMediaPreview" })
@Execute(asUser = User.USER_9)
public void previewImage() {
String mediaTitle = "Thomas Wright 1792 - 1849";
VisualEditorPageObject ve = new VisualEditorPageObject().openVEOnArticle(wikiURL, PageContent.ARTICLE_NAME_PREFIX + DateTime.now().getMillis());
ve.verifyVEToolBarPresent();
ve.verifyEditorSurfacePresent();
VisualEditorAddMediaDialog mediaDialog = ve.clickImageButton();
mediaDialog = mediaDialog.searchMedia(mediaTitle);
ve = mediaDialog.previewExistingPhotoByTitle(mediaTitle);
ve.verifyPreviewImage();
}
use of com.wikia.webdriver.pageobjectsfactory.pageobject.visualeditor.VisualEditorPageObject in project selenium-tests by Wikia.
the class VERecaptchaTests method VEAddRecaptchaTests_001_AddExternalURL.
// Verify that second click on "Save page" button changes recaptcha.
@Test(groups = { "VERecaptchaTests", "VEAddRecaptcha_001", "VEAnon" })
public void VEAddRecaptchaTests_001_AddExternalURL() {
String articleName = PageContent.ARTICLE_NAME_PREFIX + base.getTimeStamp();
VisualEditorPageObject ve = base.openVEOnArticle(wikiURL, articleName);
ve.verifyVEToolBarPresent();
ve.verifyEditorSurfacePresent();
ve.typeTextArea(URLsContent.EXTERNAL_URL);
VisualEditorSaveChangesDialog saveDialog = ve.clickPublishButton();
saveDialog = saveDialog.clickSaveWithRecaptcha();
saveDialog.verifyRecaptchaImageSrc();
String firstImgSrc = saveDialog.getRecaptchaImageSrc();
saveDialog = saveDialog.clickSaveWithRecaptcha();
saveDialog.verifyRecaptchaIsVisible();
saveDialog.verifyRecaptchaImageSrc();
saveDialog.verifyIsNewRecaptcha(firstImgSrc);
}
Aggregations