Interface AlertStateAssert

  • All Known Implementing Classes:
    AlertAssert

    public interface AlertStateAssert
    Interface for asserting the state of alert boxes.
    • Method Detail

      • hasText

        AlertStateAssert hasText​(String text)
        Check that the alert box contains the given text.

        It fails assertion when

        • there is an alert box but the text in it doesn't contain the expected text,
        • there is no alert box at all.
        Parameters:
        text - text to search for
        Returns:
        this assertion object
      • isPresent

        AlertStateAssert isPresent()
        Check that an alert box is present.
        Returns:
        this assertion object