use of com.wikia.webdriver.elements.mercury.pages.InfoboxBuilderPage in project selenium-tests by Wikia.
the class InfoboxBuilderTests method verifyNamingConflictTypingNameAfterClickingPublish.
@Test(groups = { "InfoboxBuilderTests", "InfoboxBuilder_004" })
@Execute(asUser = User.USER)
public void verifyNamingConflictTypingNameAfterClickingPublish() {
InfoboxBuilderPage builderPage = new InfoboxBuilderPage().open();
new Subhead().clickPublish();
Assertion.assertTrue(builderPage.isModalEditTitlePresent());
Assertion.assertTrue(builderPage.isEditTemplateTitleInputPresent());
builderPage.insertTemplateTitle("InfoboxNamingConflict").clickPublishEditedTitleButton();
Assertion.assertTrue(builderPage.isErrorMessagePresent());
}
use of com.wikia.webdriver.elements.mercury.pages.InfoboxBuilderPage in project selenium-tests by Wikia.
the class InfoboxBuilderTests method changeTemplateNameByClickingSubhead.
@Test(groups = { "InfoboxBuilderTests", "InfoboxBuilder_004" })
@Execute(asUser = User.USER)
public void changeTemplateNameByClickingSubhead() {
Subhead subhead = new Subhead();
InfoboxBuilderPage builderPage = new InfoboxBuilderPage().open();
subhead.clickSubheadTitle();
Assertion.assertTrue(builderPage.isModalEditTitlePresent());
Assertion.assertTrue(builderPage.isEditTemplateTitleInputPresent());
builderPage.insertTemplateTitle("InfoboxBuilderChangeTemplateNameBySubhead").clickPublishEditedTitleButton();
builderPage.waitUntilEditTitleModalIsClosed();
Assertion.assertEquals(subhead.getSubheadTitle(), "Editing template: InfoboxBuilderChangeTemplateNameBySubhead");
}
use of com.wikia.webdriver.elements.mercury.pages.InfoboxBuilderPage in project selenium-tests by Wikia.
the class InfoboxBuilderTests method setInfoboxTitleToUseArticleName.
@Test(groups = { "InfoboxBuilderTests", "InfoboxBuilder_002" })
@Execute(asUser = User.USER)
public void setInfoboxTitleToUseArticleName() {
TemplatePage template = new TemplatePage();
Sidebar builderSidebar = new Sidebar();
InfoboxBuilderPage builderPage = new InfoboxBuilderPage().openExisting("SetInfoboxTitleToUseArticleName").deleteTitleUsingPopUp(0);
builderSidebar.addTitleComponent();
builderPage.selectTitleWithIndex(0);
builderSidebar.setTitleToUseArticleName();
new Subhead().clickPublish();
Assertion.assertTrue(template.isTemplatePagePresent());
String infoboxTitle = template.getPortableInfobox().getTitleTextWithIndex(0);
Assertion.assertEquals("SetInfoboxTitleToUseArticleName", infoboxTitle);
}
use of com.wikia.webdriver.elements.mercury.pages.InfoboxBuilderPage in project selenium-tests by Wikia.
the class InfoboxBuilderTests method verifyUserInteractions.
@Test(groups = { "InfoboxBuilderTests", "InfoboxBuilder_002" })
@Execute(asUser = User.STAFF)
public void verifyUserInteractions() {
new WikiFeatures().openWikiFeatures(wikiURL).enableEuropaInfoboxTheme();
InfoboxBuilderPage builderPage = new InfoboxBuilderPage().openNew("InfoboxBuilderVerifySelectedBorderStyling").hoverMouseOverComponent(0);
Assertion.assertTrue(builderPage.isTooltipVisible(), "Component tooltip is not visible");
String borderStyle = builderPage.getBorderStyle();
Assertion.assertEquals(borderStyle, "1px solid rgb(26, 94, 184)");
borderStyle = builderPage.clickBuilderBackground().getComponentBackgroundColor(0);
Assertion.assertNotEquals(borderStyle, "1px solid rgb(26, 94, 184)");
}
use of com.wikia.webdriver.elements.mercury.pages.InfoboxBuilderPage in project selenium-tests by Wikia.
the class InfoboxBuilderTests method addingComponents.
@Test(groups = { "InfoboxBuilderTests", "InfoboxBuilder_001" })
@Execute(asUser = User.USER)
public void addingComponents() {
Sidebar builderSidebar = new Sidebar();
InfoboxBuilderPage builderPage = new InfoboxBuilderPage().openNew("InfoboxBuilderAddingComponents");
int rowComponents = builderPage.countRows();
int titleComponents = builderPage.countTitles();
int imageComponents = builderPage.countImages();
int headerComponents = builderPage.countHeaders();
builderSidebar.addRowComponent().addImageComponent().addTitleComponent().addHeaderComponent();
Assertion.assertEquals(rowComponents + 1, builderPage.countRows());
Assertion.assertEquals(titleComponents + 1, builderPage.countTitles());
Assertion.assertEquals(imageComponents + 1, builderPage.countImages());
Assertion.assertEquals(headerComponents + 1, builderPage.countHeaders());
}
Aggregations