use of com.wikia.webdriver.pageobjectsfactory.pageobject.category.CategoryPageObject in project selenium-tests by Wikia.
the class PortableInfoboxTests method verifyInfoboxCategoryLinks.
@Test(groups = { "PortableInfoboxTests", "PortableInfobox_002" })
public void verifyInfoboxCategoryLinks() {
new TemplateContent().push(INFOBOX2_TEMPLATE, PageContent.INFOBOX_2);
new ArticleContent().push(INFOBOX2_INVOCATION, PageContent.INFOBOX_2);
PortableInfobox infobox = new PortableInfobox();
infobox.open(PageContent.INFOBOX_2);
String categoryLinkName = infobox.getCategoryLinkName();
infobox.clickCategoryLink();
String categoryPageTitle = new CategoryPageObject().getCategoryPageTitle();
Assertion.assertTrue(categoryLinkName.contains(categoryPageTitle));
}
use of com.wikia.webdriver.pageobjectsfactory.pageobject.category.CategoryPageObject in project selenium-tests by Wikia.
the class PortableInfoboxTests method infoboxImageOnCategoryPage.
@Test(groups = { "PortableInfoboxTests", "PortableInfobox_002" })
@Execute(asUser = User.USER)
public void infoboxImageOnCategoryPage() {
new TemplateContent().push(INFOBOX2_TEMPLATE, PageContent.INFOBOX_2);
new ArticleContent().push(INFOBOX2_INVOCATION, PageContent.INFOBOX_2);
PortableInfobox infobox = new PortableInfobox();
infobox.open(PageContent.INFOBOX_2);
String imageName = infobox.getDataImageName();
CategoryPageObject categoryPage = infobox.clickCategoryWithIndex(0);
new ArticlePurger().purgeArticleAsLoggedUser();
String categoryImageURL = categoryPage.getImageURLFromGallery(PageContent.INFOBOX_2);
Assertion.assertTrue(categoryImageURL.contains(imageName));
}
Aggregations