use of com.wikia.webdriver.pageobjectsfactory.pageobject.article.editmode.VisualEditModePageObject in project selenium-tests by Wikia.
the class VetArticlePlaceholderTests method userCanAddVideoByUrlUsingPlaceholderInEditMode.
@Test(groups = { "VideoArticlePlacehoder_003" })
@Execute(asUser = User.STAFF, onWikia = "mobileregressiontesting")
public void userCanAddVideoByUrlUsingPlaceholderInEditMode() {
new ArticleContent().push(SourceModeContent.PLACEHOLDERS);
// Added cause of MAIN-6374 issue
new ArticlePageObject().open();
VisualEditModePageObject visualEditMode = new VisualEditModePageObject().open();
VetAddVideoComponentObject vetAddingVideo = (VetAddVideoComponentObject) visualEditMode.modifyComponent(Components.VIDEO_PLACEHOLDER);
VetOptionsComponentObject vetOptions = vetAddingVideo.addVideoByUrl(VideoContent.YOUTUBE_VIDEO_URL);
vetOptions.setCaption(PageContent.CAPTION);
vetOptions.submit();
visualEditMode.verifyVideo();
ArticlePageObject article = visualEditMode.submitArticle();
article.verifyVideo();
}
use of com.wikia.webdriver.pageobjectsfactory.pageobject.article.editmode.VisualEditModePageObject in project selenium-tests by Wikia.
the class ArticlePageObject method verifySectionEditEditor.
public void verifySectionEditEditor(Editor expectedEditor) {
switch(expectedEditor) {
case VE:
VisualEditorPageObject ve = openVEModeWithSectionEditButton(0);
ve.verifyVEToolBarPresent();
ve.verifyEditorSurfacePresent();
break;
case CK:
VisualEditModePageObject ck = openCKModeWithSectionEditButton(0);
Assertion.assertTrue(ck.isContentLoaded(), "Content is not loaded");
ck.clickPublishButton();
break;
case SRC:
SourceEditModePageObject src = openSrcModeWithSectionEditButton(0);
src.verifySourceOnlyMode();
src.clickPublishButton();
break;
}
}
use of com.wikia.webdriver.pageobjectsfactory.pageobject.article.editmode.VisualEditModePageObject in project selenium-tests by Wikia.
the class ArticlePageObject method verifyURLActionEditEditor.
public void verifyURLActionEditEditor(Editor expectedEditor, String articleName, String wikiURL) {
switch(expectedEditor) {
case CK:
VisualEditModePageObject ck = navigateToArticleEditPage(wikiURL, articleName);
Assertion.assertTrue(ck.isContentLoaded(), "Content is not loaded");
ck.clickPublishButton();
break;
case SRC:
SourceEditModePageObject src = navigateToArticleEditPageSrc(wikiURL, articleName);
src.verifySourceOnlyMode();
src.clickPublishButton();
break;
default:
throw new NoSuchElementException("Invalid expected editor chosen: " + expectedEditor.name());
}
}
use of com.wikia.webdriver.pageobjectsfactory.pageobject.article.editmode.VisualEditModePageObject in project selenium-tests by Wikia.
the class ArticlePageObject method verifyMainEditEditor.
public void verifyMainEditEditor(Editor expectedEditor) {
switch(expectedEditor) {
case VE:
VisualEditorPageObject ve = openVEModeWithMainEditButton();
ve.verifyVEToolBarPresent();
ve.verifyEditorSurfacePresent();
break;
case CK:
VisualEditModePageObject ck = openCKModeWithMainEditButton();
Assertion.assertTrue(ck.isContentLoaded(), "Content is not loaded");
ck.clickPublishButton();
break;
case SRC:
SourceEditModePageObject src = openSrcModeWithMainEditButton();
src.verifySourceOnlyMode();
src.clickPublishButton();
break;
}
}
use of com.wikia.webdriver.pageobjectsfactory.pageobject.article.editmode.VisualEditModePageObject in project selenium-tests by Wikia.
the class ArticlePageObject method createArticleInCKUsingDropdown.
public VisualEditModePageObject createArticleInCKUsingDropdown(String articleTitle) {
scrollAndClick(contributeDropdown);
wait.forElementVisible(addArticleInDropdown);
CreateArticleModalComponentObject articleModal = clickArticleInDropDown(addArticleInDropdown);
articleModal.createPageWithBlankLayout(articleTitle);
return new VisualEditModePageObject();
}
Aggregations