use of com.wikia.webdriver.pageobjectsfactory.pageobject.article.ArticlePageObject in project selenium-tests by Wikia.
the class WikiActivityTests method WikiActivityTests_004_newCategorizationIsRecordedOnActivityModule.
/**
* https://wikia-inc.atlassian.net/browse/DAR-1617
*/
@Test(groups = "WikiActivity_004")
@Execute(asUser = User.USER)
public void WikiActivityTests_004_newCategorizationIsRecordedOnActivityModule() {
ArticlePageObject article = new ArticlePageObject().open("NewCategorizationIsRecordedOnActivityModule");
String articleName = article.getArticleName();
String categoryName = PageContent.CATEGORY_NAME_PREFIX + article.getTimeStamp();
article.addCategory(categoryName);
article.submitCategory();
article.verifyCategoryPresent(categoryName);
new SpecialWikiActivityPageObject(driver).open().verifyRecentNewCategorization(articleName, credentials.userName);
}
use of com.wikia.webdriver.pageobjectsfactory.pageobject.article.ArticlePageObject in project selenium-tests by Wikia.
the class WikiActivityTests method WikiActivityTests_002_newPageCreationIsRecordedOnActivityModule.
/**
* https://wikia-inc.atlassian.net/browse/DAR-1617
*/
@Test(groups = "WikiActivity_002")
@Execute(asUser = User.USER)
public void WikiActivityTests_002_newPageCreationIsRecordedOnActivityModule() {
SpecialCreatePage specialCreatePage = new SpecialCreatePage().open();
String articleContent = PageContent.ARTICLE_TEXT;
String articleTitle = PageContent.ARTICLE_NAME_PREFIX + DateTime.now().getMillis();
VisualEditModePageObject visualEditMode = specialCreatePage.populateTitleField(articleTitle);
visualEditMode.addContent(articleContent);
ArticlePageObject article = visualEditMode.submitArticle();
String articleName = article.getArticleName();
article.verifyContent(articleContent);
article.verifyArticleTitle(articleTitle);
new SpecialWikiActivityPageObject(driver).open().verifyRecentNewPage(articleName, credentials.userName);
}
use of com.wikia.webdriver.pageobjectsfactory.pageobject.article.ArticlePageObject in project selenium-tests by Wikia.
the class VisualEditorPageObject method publish.
public ArticlePageObject publish() {
verifyVEToolBarPresent();
clickPublishButton();
new VisualEditorSaveChangesDialog(this.driver).savePage();
ArticlePageObject article = new ArticlePageObject();
article.verifyVEPublishComplete();
return article;
}
use of com.wikia.webdriver.pageobjectsfactory.pageobject.article.ArticlePageObject in project selenium-tests by Wikia.
the class ArticleActionsAdminTests method moveArticle.
@Test(groups = { "ArticleActionsAdmin_002" })
@UseUnstablePageLoadStrategy
@Execute(asUser = User.STAFF)
public void moveArticle() {
new ArticleContent().push(PageContent.ARTICLE_TEXT);
ArticlePageObject article = new ArticlePageObject().open();
String articleOldTitle = article.getArticleTitle();
String articleNewName = TestContext.getCurrentMethodName() + article.getTimeStamp();
RenamePageObject renamePage = article.renameUsingDropdown();
renamePage.rename(articleNewName, false);
List<Notification> confirmNotifications = article.getNotifications(NotificationType.CONFIRM);
Assertion.assertEquals(confirmNotifications.size(), 1, SpecialRestorePageObject.AssertionMessages.INVALID_NUMBER_OF_CONFIRMING_NOTIFICATIONS);
Assertion.assertEquals(confirmNotifications.stream().findFirst().get().getMessage(), "\"" + articleOldTitle + "\" has been renamed \"" + articleNewName + "\"", "Banner notification messsage is invalid");
Assertion.assertEquals(article.getArticleName(), articleNewName, "New article title is invalid");
}
use of com.wikia.webdriver.pageobjectsfactory.pageobject.article.ArticlePageObject in project selenium-tests by Wikia.
the class ArticleCRUDAnonTests method articleCRUDAnon_addByURL.
@Test(groups = { "ArticleCRUDAnon_002" })
public void articleCRUDAnon_addByURL() {
String articleContent = PageContent.ARTICLE_TEXT;
String articleTitle = PageContent.ARTICLE_NAME_PREFIX + DateTime.now().getMillis();
VisualEditModePageObject visualEditMode = new ArticlePageObject().navigateToArticleEditPage(wikiURL, articleTitle);
visualEditMode.addContent(articleContent);
ArticlePageObject article = visualEditMode.submitExpectingNotification().submitArticle();
article.verifyContent(articleContent);
article.verifyArticleTitle(articleTitle);
}
Aggregations