com.sdl.selenium.bootstrap.window.Window Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of Testy Show documentation
Show all versions of Testy Show documentation
Automated Acceptance Testing. Selenium and Selenium WebDriver test framework for web applications.
(optimized for dynamic html, ExtJS, Bootstrap, complex UI, simple web applications/sites)
The newest version!
package com.sdl.selenium.bootstrap.window;
import com.sdl.selenium.web.IWebLocator;
import com.sdl.selenium.web.SearchType;
import com.sdl.selenium.web.WebLocator;
public class Window extends WebLocator implements IWebLocator {
public Window() {
setClassName("Window");
// setTemplate("title", "count(*[contains(@class,'-header')]//*[text()='%s']) > 0"); //TODO make sure setTemplate Title is working
WebLocator header = new WebLocator().setClasses("modal-header");
setTemplateTitle(new WebLocator(header));
setAttribute("role", "dialog");
setAttribute("aria-hidden", "false");
}
public Window(String title) {
this();
setTitle(title, SearchType.EQUALS);
}
public String getTitleWindow() {
WebLocator header = new WebLocator(this).setElPath("//*[contains(@class, '-header')]//h3");
return header.getText();
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy