use of com.wikia.webdriver.common.core.api.ArticleContent in project selenium-tests by Wikia.
the class VideosModuleTests method VideosModuleTest_003.
/**
* Checks if the Videos Module is showing the correct number of videos. Currently that amount is
* between 3 and 5.
*/
@Test(groups = { "VideosModule", "VideosModuleTest_003", "Media" })
public void VideosModuleTest_003() {
new ArticleContent().push(PageContent.ARTICLE_TEXT);
new ArticlePageObject().open();
new VideosModuleComponentObject(driver).verifyDisplayCount();
}
use of com.wikia.webdriver.common.core.api.ArticleContent in project selenium-tests by Wikia.
the class CategoryPageTest method mercury_category_navigateToCategoryPageWithArticleAndWithoutMembersFromUrl.
@Test(groups = "mercury_category_navigateToCategoryPageWithArticleAndWithoutMembersFromUrl")
public void mercury_category_navigateToCategoryPageWithArticleAndWithoutMembersFromUrl() {
final String categoryName = String.format("Category:%s", TestContext.getCurrentMethodName());
new ArticleContent().push("some irrelevant content of category article", categoryName);
CategoryPage category = new CategoryPage().open(categoryName);
Assert.assertEquals(404, category.getURLStatus(category.getCurrentUrl()));
}
use of com.wikia.webdriver.common.core.api.ArticleContent in project selenium-tests by Wikia.
the class VisualEditorEditingTests method VisualEditorEditing_003_insertToExistingArticle.
@Test(groups = { "VisualEditorEditing", "VisualEditorEditing_003" })
public void VisualEditorEditing_003_insertToExistingArticle() {
new ArticleContent().push(startingWikiText);
VisualEditorPageObject ve = new VisualEditorPageObject().open();
ve.verifyVEToolBarPresent();
ve.verifyEditorSurfacePresent();
ve.putCursorAtTheEnd();
ve.typeReturn();
ve.typeReturn();
ve.typeTextInAllFormat(text);
ve.typeTextInAllStyle(text);
ve.typeTextInAllList(text);
VisualEditorSaveChangesDialog saveDialog = ve.clickPublishButton();
VisualEditorReviewChangesDialog reviewDialog = saveDialog.clickReviewYourChanges();
reviewDialog.verifyAddedDiffs(wikiTexts);
saveDialog = reviewDialog.clickReturnToSaveFormButton();
ArticlePageObject article = saveDialog.savePage();
article.verifyVEPublishComplete();
article.verifyContent(text);
}
use of com.wikia.webdriver.common.core.api.ArticleContent in project selenium-tests by Wikia.
the class ArticleFeaturesCRUDTestsUser method deleteTable.
@Test(dataProviderClass = ArticleFeaturesCRUDDataProvider.class, dataProvider = "getTableProperties", groups = { "ArticleFeaturesCRUDUser_013" })
@Execute(asUser = User.USER)
public void deleteTable(int border, int width, int height, int cellspacing, int cellpadding, Alignment alignment) {
new ArticleContent().push(String.format("{| border=\"%d\" cellpadding=\"%d\" cellspacing=\"%d\" " + "class=\"article-table article-table-selected\" " + "style=\"float: %s; height: %dpx; width: %dpx;\"\n" + "! scope=\"row\"|\n|\n|-\n! scope=\"row\"|\n|\n" + "|-\n! scope=\"row\"|\n|\n" + "|}", border, cellpadding, cellspacing, alignment.getAlignment(), height, width));
VisualEditModePageObject visualEditMode = new VisualEditModePageObject().open();
visualEditMode.clickDeleteTableButton();
visualEditMode.submitArticle().verifyTableRemoved();
}
use of com.wikia.webdriver.common.core.api.ArticleContent in project selenium-tests by Wikia.
the class ArticleFeaturesCRUDTestsUser method modifyTable.
@Test(dataProviderClass = ArticleFeaturesCRUDDataProvider.class, dataProvider = "getTableProperties", groups = { "ArticleFeaturesCRUDUser_012" }, enabled = false)
@Execute(asUser = User.USER)
public void modifyTable(int border, int width, int height, int cellspacing, int cellpadding, Alignment alignment) {
new ArticleContent().push(String.format("{| border=\"%d\" cellpadding=\"%d\" cellspacing=\"%d\" " + "class=\"article-table article-table-selected\" " + "style=\"float: %s; height: %dpx; width: %dpx;\"\n" + "! scope=\"row\"|\n|\n|-\n! scope=\"row\"|\n|\n" + "|-\n! scope=\"row\"|\n|\n" + "|}", border, cellpadding, cellspacing, alignment.getAlignment(), height, width));
VisualEditModePageObject visualEditMode = new VisualEditModePageObject().open();
visualEditMode.clickPropertiesTableButton();
TableBuilderComponentObject addTable = new TableBuilderComponentObject(driver);
addTable.typeBorderSize(border + additionalPropertyValue);
addTable.typeCellSpacing(cellspacing + additionalPropertyValue);
addTable.typeCellPadding(cellpadding + additionalPropertyValue);
addTable.submitTable();
ArticlePageObject article = visualEditMode.submitArticle();
article.verifyTableBorder(border + additionalPropertyValue);
article.verifyTableCellspacing(cellspacing + additionalPropertyValue);
article.verifyTableCellpadding(cellpadding + additionalPropertyValue);
}
Aggregations