Class AttributeWithValue
- java.lang.Object
-
- com.codeborne.selenide.Condition
-
- com.codeborne.selenide.conditions.AttributeWithValue
-
-
Field Summary
Fields Modifier and Type Field Description protected java.lang.String
expectedAttributeValue
-
Constructor Summary
Constructors Constructor Description AttributeWithValue(java.lang.String attributeName, java.lang.String expectedAttributeValue)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
actualValue(Driver driver, org.openqa.selenium.WebElement element)
If element didn't match the condition, returns the actual value of element.boolean
apply(Driver driver, org.openqa.selenium.WebElement element)
Check if given element matches this condition.protected java.lang.String
getAttributeValue(org.openqa.selenium.WebElement element)
java.lang.String
toString()
-
Methods inherited from class com.codeborne.selenide.Condition
and, applyNull, attribute, attribute, attributeMatching, be, because, cssClass, cssValue, exactOwnText, exactText, exactTextCaseSensitive, exactValue, getName, have, href, id, match, matchesText, matchText, missingElementSatisfiesCondition, name, negate, not, or, ownText, pseudo, pseudo, selectedText, text, textCaseSensitive, type, value
-
-
-
-
Method Detail
-
apply
@CheckReturnValue public boolean apply(Driver driver, org.openqa.selenium.WebElement element)
Description copied from class:Condition
Check if given element matches this condition.
-
actualValue
@Nonnull @CheckReturnValue public java.lang.String actualValue(Driver driver, org.openqa.selenium.WebElement element)
Description copied from class:Condition
If element didn't match the condition, returns the actual value of element. Used in error reporting. Optional. Makes sense only if you need to add some additional important info to error message.- Overrides:
actualValue
in classCondition
- Parameters:
driver
- given driverelement
- given WebElement- Returns:
- any string that needs to be appended to error message.
-
toString
@Nonnull @CheckReturnValue public java.lang.String toString()
-
getAttributeValue
protected java.lang.String getAttributeValue(org.openqa.selenium.WebElement element)
-
-