net.serenitybdd.screenplay.actions.HtmlAlert Maven / Gradle / Ivy
package net.serenitybdd.screenplay.actions;
import net.serenitybdd.screenplay.Question;
import net.serenitybdd.screenplay.abilities.BrowseTheWeb;
public class HtmlAlert {
/**
* Retrieve the text of the current alert window
*/
public static Question text() {
return actor -> BrowseTheWeb.as(actor).getDriver().switchTo().alert().getText();
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy