Class UIAssertionError

java.lang.Object
java.lang.Throwable
java.lang.Error
java.lang.AssertionError
org.opentest4j.AssertionFailedError
com.codeborne.selenide.ex.UIAssertionError
All Implemented Interfaces:
Serializable
Direct Known Subclasses:
AlertNotFoundError, AttributesMismatch, ConditionMetError, ConditionNotMetError, DialogTextMismatch, DoesNotContainTextsError, ElementIsNotClickableError, ElementNotFound, ElementShould, ElementShouldNot, ElementWithTextNotFound, FileNotDownloadedError, FrameNotFoundError, InvalidStateError, ListSizeMismatch, MatcherError, TextsMismatch, WindowNotFoundError

@ParametersAreNonnullByDefault public class UIAssertionError extends org.opentest4j.AssertionFailedError
See Also:
  • Field Details

    • errorFormatter

      protected static final ErrorFormatter errorFormatter
  • Constructor Details

    • UIAssertionError

      protected UIAssertionError(Driver driver, String message)
    • UIAssertionError

      public UIAssertionError(Driver driver, String message, @Nullable Object expected, @Nullable Object actual)
    • UIAssertionError

      protected UIAssertionError(Driver driver, String message, @Nullable Object expected, @Nullable Object actual, long timeoutMs)
    • UIAssertionError

      protected UIAssertionError(Driver driver, String message, @Nullable Throwable cause)
    • UIAssertionError

      protected UIAssertionError(Driver driver, String message, long timeoutMs, @Nullable Throwable cause)
    • UIAssertionError

      protected UIAssertionError(Driver driver, String message, @Nullable Object expected, @Nullable Object actual, @Nullable Throwable cause)
    • UIAssertionError

      protected UIAssertionError(Driver driver, String message, @Nullable Object expected, @Nullable Object actual, @Nullable Throwable cause, long timeoutMs)
  • Method Details

    • getMessage

      @CheckReturnValue public final String getMessage()
      Overrides:
      getMessage in class Throwable
    • toString

      @CheckReturnValue public final String toString()
      Overrides:
      toString in class org.opentest4j.AssertionFailedError
    • getScreenshot

      @CheckReturnValue public Screenshot getScreenshot()
      Get path to screenshot taken after failed test
      Returns:
      empty string if screenshots are disabled
    • wrap

      @CheckReturnValue public static Error wrap(Driver driver, Error error, long timeoutMs)
    • wrap

      @CheckReturnValue public static Throwable wrap(Driver driver, org.openqa.selenium.WebDriverException error, long timeoutMs)