final class RangeField extends ValueElement
This class is part of ScalaTest's Selenium DSL. Please see the documentation for
WebBrowser
for an overview of the Selenium DSL.
This class enables syntax such as the following:
rangeField("q").value should be ("1.3")
- Source
- WebBrowser.scala
- Exceptions thrown
TestFailedExeption
if the passedWebElement
does not represent a range field
- Alphabetic
- By Inheritance
- RangeField
- ValueElement
- Element
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Instance Constructors
-
new
RangeField(underlying: WebElement)(implicit pos: Position)
- underlying
the
WebElement
representing a range field
- Exceptions thrown
TestFailedExeption
if the passedWebElement
does not represent a range field
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
attribute(name: String): Option[String]
The attribute value of the given attribute name of this element, wrapped in a
Some
, orNone
if no such attribute exists on thisElement
.The attribute value of the given attribute name of this element, wrapped in a
Some
, orNone
if no such attribute exists on thisElement
.This method invokes
getAttribute
on the underlyingWebElement
, passing in the specifiedname
.- returns
the attribute with the given name, wrapped in a
Some
, elseNone
- Definition Classes
- Element
-
def
clear(): Unit
Clears this field.
Clears this field.
- Definition Classes
- ValueElement
-
def
clone(): AnyRef
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @native() @throws( ... )
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(other: Any): Boolean
Returns the result of invoking
equals
on the underlyingElement
, passing in the specifiedother
object.Returns the result of invoking
equals
on the underlyingElement
, passing in the specifiedother
object.- other
the object with which to compare for equality
- returns
true if the passed object is equal to this one
- Definition Classes
- Element → AnyRef → Any
-
def
finalize(): Unit
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
hashCode(): Int
Returns the result of invoking
hashCode
on the underlyingElement
.Returns the result of invoking
hashCode
on the underlyingElement
.- returns
a hash code for this object
- Definition Classes
- Element → AnyRef → Any
-
def
isDisplayed: Boolean
Indicates whether this
Element
is displayed.Indicates whether this
Element
is displayed.This invokes
isDisplayed
on the underlyingWebElement
.- returns
true
if the element is currently displayed
- Definition Classes
- Element
-
def
isEnabled: Boolean
Indicates whether this
Element
is enabled.Indicates whether this
Element
is enabled.This invokes
isEnabled
on the underlyingWebElement
, which will generally returntrue
for everything but disabled input elements.- returns
true
if the element is currently enabled
- Definition Classes
- Element
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
def
isSelected: Boolean
Indicates whether this
Element
is selected.Indicates whether this
Element
is selected.This method, which invokes
isSelected
on the underlyingWebElement
, is relevant only for input elements such as checkboxes, options in a single- or multiple-selection list box, and radio buttons. For any other element it will simply returnfalse
.- returns
true
if the element is currently selected or checked
- Definition Classes
- Element
-
def
location: Point
The XY location of the top-left corner of this
Element
.The XY location of the top-left corner of this
Element
.This invokes
getLocation
on the underlyingWebElement
.- returns
the location of the top-left corner of this element on the page
- Definition Classes
- Element
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
def
size: Dimension
The width/height size of this
Element
.The width/height size of this
Element
.This invokes
getSize
on the underlyingWebElement
.- returns
the size of the element on the page
- Definition Classes
- Element
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
tagName: String
The tag name of this element.
The tag name of this element.
This method invokes
getTagName
on the underlyingWebElement
. Note it returns the name of the tag, not the value of the of thename
attribute. For example, it will return will return"input"
for the element<input name="city" />
, not"city"
.- returns
the tag name of this element
- Definition Classes
- Element
-
def
text: String
Returns the visible (i.e., not hidden by CSS) text of this element, including sub-elements, without any leading or trailing whitespace.
Returns the visible (i.e., not hidden by CSS) text of this element, including sub-elements, without any leading or trailing whitespace.
- returns
the visible text enclosed by this element, or an empty string, if the element encloses no visible text
- Definition Classes
- Element
-
def
toString(): String
Returns the result of invoking
toString
on the underlyingElement
.Returns the result of invoking
toString
on the underlyingElement
.- returns
a string representation of this object
- Definition Classes
- Element → AnyRef → Any
-
val
underlying: WebElement
The underlying
WebElement
wrapped by thisElement
The underlying
WebElement
wrapped by thisElement
- Definition Classes
- RangeField → ValueElement → Element
-
def
value: String
Gets this field's value.
Gets this field's value.
This method invokes
getAttribute("value")
on the underlyingWebElement
.- returns
the field's value
- Definition Classes
- ValueElement
-
def
value_=(value: String): Unit
Sets this field's value.
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @throws( ... )
Deprecated Value Members
-
def
checkCorrectType(isA: (TagMeta) ⇒ Boolean, typeDescription: String)(implicit pos: Position): Unit
- Definition Classes
- ValueElement
- Annotations
- @deprecated
- Deprecated
This method is internal which is not intended to be called by user, we plan to remove it in the future version of ScalaTest, if you did use it, please kindly let us know by contacting us.