enum Marionette::LocationStrategy

Defined in:

marionette/location_stategy.cr

Enum Members

ID = 0

Search using the HTML id property of the given element.

XPath = 1

Search using an XPath expression. Here is a helpful XPath cheatsheet.

LinkText = 2

Use the text of a given link to search.

PartialLinkText = 3

Use only some of a given link's text to search.

Name = 4

Search using the HTML name property of the given element.

TagName = 5

Search using a tag name (i.e. div or span)

ClassName = 6

Search using a the HTML class property of a given element.

Css = 7

Search using a standard CSS selector. (i.e. #some-element li:nth-child(2) > a)

Instance Method Summary

Instance Method Detail

def class_name? #

[View source]
def css? #

[View source]
def id? #

[View source]
def link_text? #

[View source]
def name? #

[View source]
def partial_link_text? #

[View source]
def tag_name? #

[View source]
def to_s #
Description copied from struct Enum

Returns a String representation of this enum member. In the case of regular enums, this is just the name of the member. In the case of flag enums, it's the names joined by vertical bars, or "None", if the value is zero.

If an enum's value doesn't match a member's value, the raw value is returned as a string.

Color::Red.to_s                     # => "Red"
IOMode::None.to_s                   # => "None"
(IOMode::Read | IOMode::Write).to_s # => "Read | Write"

Color.new(10).to_s # => "10"

[View source]
def x_path? #

[View source]