Module pom_elements.html.forms

Expand source code
from pom_elements import XPathElement


class Button(XPathElement):
    """Interact with <button> html dom elements."""

    tag = "button"


class DataList(XPathElement):
    """Interact with <datalist> html dom elements."""

    tag = "datalist"


class Fieldset(XPathElement):
    """Interact with <fieldset> html dom elements."""

    tag = "fieldset"


class Form(XPathElement):
    """Interact with <form> html dom elements."""

    tag = "form"


class Input(XPathElement):
    """Interact with <input> html dom elements."""

    tag = "input"


class Label(XPathElement):
    """Interact with <label> html dom elements."""

    tag = "label"


class Legend(XPathElement):
    """Interact with <legend> html dom elements."""

    tag = "legend"


class Meter(XPathElement):
    """Interact with <meter> html dom elements."""

    tag = "meter"


class OptGroup(XPathElement):
    """Interact with <optgroup> html dom elements."""

    tag = "optgroup"


class Option(XPathElement):
    """Interact with <option> html dom elements."""

    tag = "option"


class Select(XPathElement):
    """Interact with <select> html dom elements."""

    tag = "select"


class TextArea(XPathElement):
    """Interact with <textarea> html dom elements."""

    tag = "textarea"

Classes

class Button (webdriver:  = None, timeout: int = 5, xpath: str = '', **kwargs)

Interact with

Expand source code
class Button(XPathElement):
    """Interact with <button> html dom elements."""

    tag = "button"

Ancestors

Class variables

var tag

Inherited from: XPathElement.tag

tag class attribute is the xpath html tag (i.e. div, span, ul).

Instance variables

var default_timeout

Inherited from: XPathElement.default_timeout

Get the default timeout.

var locator : Tuple[selenium.webdriver.common.by.By, str]

Inherited from: XPathElement.locator

Return the Xpath Locator element.

var webdriver

Inherited from: XPathElement.webdriver

Get the Element's Selenium webdriver instance …

var xpath : str

Inherited from: XPathElement.xpath

Get the xpath value as a string.

Methods

def can_be_clicked(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.can_be_clicked

Return true if the webelement can be clicked in the time (seconds) provided …

def click(self, timeout: Union[float, NoneType] = None)

Inherited from: XPathElement.click

Click the web element if it is available to be clicked.

def find(self, timeout: Union[float, NoneType] = None) -> selenium.webdriver.remote.webelement.WebElement

Inherited from: XPathElement.find

Return the Selenium WebElement in the provided timeout or raise an error …

def get_all_attributes(self) -> dict

Inherited from: XPathElement.get_all_attributes

Return a dictionary containing all of the attributes of an element.

def get_attribute(self, name)

Inherited from: XPathElement.get_attribute

Returns the attribute of the name provided.

def get_property(self, value: str) -> Any

Inherited from: XPathElement.get_property

Get the property of the element …

def is_displayed(self)

Inherited from: XPathElement.is_displayed

Returns true if the Element is displayed else false.

def is_invisible(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.is_invisible

Return true if the webelement is invisible on the page within the time (seconds) provided …

def is_visible(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.is_visible

Return true if the webelement is visible on the page in the time (seconds) provided …

class DataList (webdriver:  = None, timeout: int = 5, xpath: str = '', **kwargs)

Interact with html dom elements.

Expand source code
class DataList(XPathElement):
    """Interact with <datalist> html dom elements."""

    tag = "datalist"

Ancestors

Class variables

var tag

Inherited from: XPathElement.tag

tag class attribute is the xpath html tag (i.e. div, span, ul).

Instance variables

var default_timeout

Inherited from: XPathElement.default_timeout

Get the default timeout.

var locator : Tuple[selenium.webdriver.common.by.By, str]

Inherited from: XPathElement.locator

Return the Xpath Locator element.

var webdriver

Inherited from: XPathElement.webdriver

Get the Element's Selenium webdriver instance …

var xpath : str

Inherited from: XPathElement.xpath

Get the xpath value as a string.

Methods

def can_be_clicked(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.can_be_clicked

Return true if the webelement can be clicked in the time (seconds) provided …

def click(self, timeout: Union[float, NoneType] = None)

Inherited from: XPathElement.click

Click the web element if it is available to be clicked.

def find(self, timeout: Union[float, NoneType] = None) -> selenium.webdriver.remote.webelement.WebElement

Inherited from: XPathElement.find

Return the Selenium WebElement in the provided timeout or raise an error …

def get_all_attributes(self) -> dict

Inherited from: XPathElement.get_all_attributes

Return a dictionary containing all of the attributes of an element.

def get_attribute(self, name)

Inherited from: XPathElement.get_attribute

Returns the attribute of the name provided.

def get_property(self, value: str) -> Any

Inherited from: XPathElement.get_property

Get the property of the element …

def is_displayed(self)

Inherited from: XPathElement.is_displayed

Returns true if the Element is displayed else false.

def is_invisible(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.is_invisible

Return true if the webelement is invisible on the page within the time (seconds) provided …

def is_visible(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.is_visible

Return true if the webelement is visible on the page in the time (seconds) provided …

class Fieldset (webdriver:  = None, timeout: int = 5, xpath: str = '', **kwargs)

Interact with

html dom elements.

Expand source code
class Fieldset(XPathElement):
    """Interact with <fieldset> html dom elements."""

    tag = "fieldset"

Ancestors

Class variables

var tag

Inherited from: XPathElement.tag

tag class attribute is the xpath html tag (i.e. div, span, ul).

Instance variables

var default_timeout

Inherited from: XPathElement.default_timeout

Get the default timeout.

var locator : Tuple[selenium.webdriver.common.by.By, str]

Inherited from: XPathElement.locator

Return the Xpath Locator element.

var webdriver

Inherited from: XPathElement.webdriver

Get the Element's Selenium webdriver instance …

var xpath : str

Inherited from: XPathElement.xpath

Get the xpath value as a string.

Methods

def can_be_clicked(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.can_be_clicked

Return true if the webelement can be clicked in the time (seconds) provided …

def click(self, timeout: Union[float, NoneType] = None)

Inherited from: XPathElement.click

Click the web element if it is available to be clicked.

def find(self, timeout: Union[float, NoneType] = None) -> selenium.webdriver.remote.webelement.WebElement

Inherited from: XPathElement.find

Return the Selenium WebElement in the provided timeout or raise an error …

def get_all_attributes(self) -> dict

Inherited from: XPathElement.get_all_attributes

Return a dictionary containing all of the attributes of an element.

def get_attribute(self, name)

Inherited from: XPathElement.get_attribute

Returns the attribute of the name provided.

def get_property(self, value: str) -> Any

Inherited from: XPathElement.get_property

Get the property of the element …

def is_displayed(self)

Inherited from: XPathElement.is_displayed

Returns true if the Element is displayed else false.

def is_invisible(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.is_invisible

Return true if the webelement is invisible on the page within the time (seconds) provided …

def is_visible(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.is_visible

Return true if the webelement is visible on the page in the time (seconds) provided …

class Form (webdriver:  = None, timeout: int = 5, xpath: str = '', **kwargs)

Interact with

html dom elements.

Expand source code
class Form(XPathElement):
    """Interact with <form> html dom elements."""

    tag = "form"

Ancestors

Class variables

var tag

Inherited from: XPathElement.tag

tag class attribute is the xpath html tag (i.e. div, span, ul).

Instance variables

var default_timeout

Inherited from: XPathElement.default_timeout

Get the default timeout.

var locator : Tuple[selenium.webdriver.common.by.By, str]

Inherited from: XPathElement.locator

Return the Xpath Locator element.

var webdriver

Inherited from: XPathElement.webdriver

Get the Element's Selenium webdriver instance …

var xpath : str

Inherited from: XPathElement.xpath

Get the xpath value as a string.

Methods

def can_be_clicked(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.can_be_clicked

Return true if the webelement can be clicked in the time (seconds) provided …

def click(self, timeout: Union[float, NoneType] = None)

Inherited from: XPathElement.click

Click the web element if it is available to be clicked.

def find(self, timeout: Union[float, NoneType] = None) -> selenium.webdriver.remote.webelement.WebElement

Inherited from: XPathElement.find

Return the Selenium WebElement in the provided timeout or raise an error …

def get_all_attributes(self) -> dict

Inherited from: XPathElement.get_all_attributes

Return a dictionary containing all of the attributes of an element.

def get_attribute(self, name)

Inherited from: XPathElement.get_attribute

Returns the attribute of the name provided.

def get_property(self, value: str) -> Any

Inherited from: XPathElement.get_property

Get the property of the element …

def is_displayed(self)

Inherited from: XPathElement.is_displayed

Returns true if the Element is displayed else false.

def is_invisible(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.is_invisible

Return true if the webelement is invisible on the page within the time (seconds) provided …

def is_visible(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.is_visible

Return true if the webelement is visible on the page in the time (seconds) provided …

class Input (webdriver:  = None, timeout: int = 5, xpath: str = '', **kwargs)

Interact with html dom elements.

Expand source code
class Input(XPathElement):
    """Interact with <input> html dom elements."""

    tag = "input"

Ancestors

Class variables

var tag

Inherited from: XPathElement.tag

tag class attribute is the xpath html tag (i.e. div, span, ul).

Instance variables

var default_timeout

Inherited from: XPathElement.default_timeout

Get the default timeout.

var locator : Tuple[selenium.webdriver.common.by.By, str]

Inherited from: XPathElement.locator

Return the Xpath Locator element.

var webdriver

Inherited from: XPathElement.webdriver

Get the Element's Selenium webdriver instance …

var xpath : str

Inherited from: XPathElement.xpath

Get the xpath value as a string.

Methods

def can_be_clicked(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.can_be_clicked

Return true if the webelement can be clicked in the time (seconds) provided …

def click(self, timeout: Union[float, NoneType] = None)

Inherited from: XPathElement.click

Click the web element if it is available to be clicked.

def find(self, timeout: Union[float, NoneType] = None) -> selenium.webdriver.remote.webelement.WebElement

Inherited from: XPathElement.find

Return the Selenium WebElement in the provided timeout or raise an error …

def get_all_attributes(self) -> dict

Inherited from: XPathElement.get_all_attributes

Return a dictionary containing all of the attributes of an element.

def get_attribute(self, name)

Inherited from: XPathElement.get_attribute

Returns the attribute of the name provided.

def get_property(self, value: str) -> Any

Inherited from: XPathElement.get_property

Get the property of the element …

def is_displayed(self)

Inherited from: XPathElement.is_displayed

Returns true if the Element is displayed else false.

def is_invisible(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.is_invisible

Return true if the webelement is invisible on the page within the time (seconds) provided …

def is_visible(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.is_visible

Return true if the webelement is visible on the page in the time (seconds) provided …

class Label (webdriver:  = None, timeout: int = 5, xpath: str = '', **kwargs)

Interact with

Expand source code
class Label(XPathElement):
    """Interact with <label> html dom elements."""

    tag = "label"

Ancestors

Class variables

var tag

Inherited from: XPathElement.tag

tag class attribute is the xpath html tag (i.e. div, span, ul).

Instance variables

var default_timeout

Inherited from: XPathElement.default_timeout

Get the default timeout.

var locator : Tuple[selenium.webdriver.common.by.By, str]

Inherited from: XPathElement.locator

Return the Xpath Locator element.

var webdriver

Inherited from: XPathElement.webdriver

Get the Element's Selenium webdriver instance …

var xpath : str

Inherited from: XPathElement.xpath

Get the xpath value as a string.

Methods

def can_be_clicked(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.can_be_clicked

Return true if the webelement can be clicked in the time (seconds) provided …

def click(self, timeout: Union[float, NoneType] = None)

Inherited from: XPathElement.click

Click the web element if it is available to be clicked.

def find(self, timeout: Union[float, NoneType] = None) -> selenium.webdriver.remote.webelement.WebElement

Inherited from: XPathElement.find

Return the Selenium WebElement in the provided timeout or raise an error …

def get_all_attributes(self) -> dict

Inherited from: XPathElement.get_all_attributes

Return a dictionary containing all of the attributes of an element.

def get_attribute(self, name)

Inherited from: XPathElement.get_attribute

Returns the attribute of the name provided.

def get_property(self, value: str) -> Any

Inherited from: XPathElement.get_property

Get the property of the element …

def is_displayed(self)

Inherited from: XPathElement.is_displayed

Returns true if the Element is displayed else false.

def is_invisible(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.is_invisible

Return true if the webelement is invisible on the page within the time (seconds) provided …

def is_visible(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.is_visible

Return true if the webelement is visible on the page in the time (seconds) provided …

class Legend (webdriver:  = None, timeout: int = 5, xpath: str = '', **kwargs)

Interact with html dom elements.

Expand source code
class Legend(XPathElement):
    """Interact with <legend> html dom elements."""

    tag = "legend"

Ancestors

Class variables

var tag

Inherited from: XPathElement.tag

tag class attribute is the xpath html tag (i.e. div, span, ul).

Instance variables

var default_timeout

Inherited from: XPathElement.default_timeout

Get the default timeout.

var locator : Tuple[selenium.webdriver.common.by.By, str]

Inherited from: XPathElement.locator

Return the Xpath Locator element.

var webdriver

Inherited from: XPathElement.webdriver

Get the Element's Selenium webdriver instance …

var xpath : str

Inherited from: XPathElement.xpath

Get the xpath value as a string.

Methods

def can_be_clicked(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.can_be_clicked

Return true if the webelement can be clicked in the time (seconds) provided …

def click(self, timeout: Union[float, NoneType] = None)

Inherited from: XPathElement.click

Click the web element if it is available to be clicked.

def find(self, timeout: Union[float, NoneType] = None) -> selenium.webdriver.remote.webelement.WebElement

Inherited from: XPathElement.find

Return the Selenium WebElement in the provided timeout or raise an error …

def get_all_attributes(self) -> dict

Inherited from: XPathElement.get_all_attributes

Return a dictionary containing all of the attributes of an element.

def get_attribute(self, name)

Inherited from: XPathElement.get_attribute

Returns the attribute of the name provided.

def get_property(self, value: str) -> Any

Inherited from: XPathElement.get_property

Get the property of the element …

def is_displayed(self)

Inherited from: XPathElement.is_displayed

Returns true if the Element is displayed else false.

def is_invisible(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.is_invisible

Return true if the webelement is invisible on the page within the time (seconds) provided …

def is_visible(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.is_visible

Return true if the webelement is visible on the page in the time (seconds) provided …

class Meter (webdriver:  = None, timeout: int = 5, xpath: str = '', **kwargs)

Interact with html dom elements.

Expand source code
class Meter(XPathElement):
    """Interact with <meter> html dom elements."""

    tag = "meter"

Ancestors

Class variables

var tag

Inherited from: XPathElement.tag

tag class attribute is the xpath html tag (i.e. div, span, ul).

Instance variables

var default_timeout

Inherited from: XPathElement.default_timeout

Get the default timeout.

var locator : Tuple[selenium.webdriver.common.by.By, str]

Inherited from: XPathElement.locator

Return the Xpath Locator element.

var webdriver

Inherited from: XPathElement.webdriver

Get the Element's Selenium webdriver instance …

var xpath : str

Inherited from: XPathElement.xpath

Get the xpath value as a string.

Methods

def can_be_clicked(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.can_be_clicked

Return true if the webelement can be clicked in the time (seconds) provided …

def click(self, timeout: Union[float, NoneType] = None)

Inherited from: XPathElement.click

Click the web element if it is available to be clicked.

def find(self, timeout: Union[float, NoneType] = None) -> selenium.webdriver.remote.webelement.WebElement

Inherited from: XPathElement.find

Return the Selenium WebElement in the provided timeout or raise an error …

def get_all_attributes(self) -> dict

Inherited from: XPathElement.get_all_attributes

Return a dictionary containing all of the attributes of an element.

def get_attribute(self, name)

Inherited from: XPathElement.get_attribute

Returns the attribute of the name provided.

def get_property(self, value: str) -> Any

Inherited from: XPathElement.get_property

Get the property of the element …

def is_displayed(self)

Inherited from: XPathElement.is_displayed

Returns true if the Element is displayed else false.

def is_invisible(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.is_invisible

Return true if the webelement is invisible on the page within the time (seconds) provided …

def is_visible(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.is_visible

Return true if the webelement is visible on the page in the time (seconds) provided …

class OptGroup (webdriver:  = None, timeout: int = 5, xpath: str = '', **kwargs)

Interact with html dom elements.

Expand source code
class OptGroup(XPathElement):
    """Interact with <optgroup> html dom elements."""

    tag = "optgroup"

Ancestors

Class variables

var tag

Inherited from: XPathElement.tag

tag class attribute is the xpath html tag (i.e. div, span, ul).

Instance variables

var default_timeout

Inherited from: XPathElement.default_timeout

Get the default timeout.

var locator : Tuple[selenium.webdriver.common.by.By, str]

Inherited from: XPathElement.locator

Return the Xpath Locator element.

var webdriver

Inherited from: XPathElement.webdriver

Get the Element's Selenium webdriver instance …

var xpath : str

Inherited from: XPathElement.xpath

Get the xpath value as a string.

Methods

def can_be_clicked(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.can_be_clicked

Return true if the webelement can be clicked in the time (seconds) provided …

def click(self, timeout: Union[float, NoneType] = None)

Inherited from: XPathElement.click

Click the web element if it is available to be clicked.

def find(self, timeout: Union[float, NoneType] = None) -> selenium.webdriver.remote.webelement.WebElement

Inherited from: XPathElement.find

Return the Selenium WebElement in the provided timeout or raise an error …

def get_all_attributes(self) -> dict

Inherited from: XPathElement.get_all_attributes

Return a dictionary containing all of the attributes of an element.

def get_attribute(self, name)

Inherited from: XPathElement.get_attribute

Returns the attribute of the name provided.

def get_property(self, value: str) -> Any

Inherited from: XPathElement.get_property

Get the property of the element …

def is_displayed(self)

Inherited from: XPathElement.is_displayed

Returns true if the Element is displayed else false.

def is_invisible(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.is_invisible

Return true if the webelement is invisible on the page within the time (seconds) provided …

def is_visible(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.is_visible

Return true if the webelement is visible on the page in the time (seconds) provided …

class Option (webdriver:  = None, timeout: int = 5, xpath: str = '', **kwargs)

Interact with

Expand source code
class Option(XPathElement):
    """Interact with <option> html dom elements."""

    tag = "option"

Ancestors

Class variables

var tag

Inherited from: XPathElement.tag

tag class attribute is the xpath html tag (i.e. div, span, ul).

Instance variables

var default_timeout

Inherited from: XPathElement.default_timeout

Get the default timeout.

var locator : Tuple[selenium.webdriver.common.by.By, str]

Inherited from: XPathElement.locator

Return the Xpath Locator element.

var webdriver

Inherited from: XPathElement.webdriver

Get the Element's Selenium webdriver instance …

var xpath : str

Inherited from: XPathElement.xpath

Get the xpath value as a string.

Methods

def can_be_clicked(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.can_be_clicked

Return true if the webelement can be clicked in the time (seconds) provided …

def click(self, timeout: Union[float, NoneType] = None)

Inherited from: XPathElement.click

Click the web element if it is available to be clicked.

def find(self, timeout: Union[float, NoneType] = None) -> selenium.webdriver.remote.webelement.WebElement

Inherited from: XPathElement.find

Return the Selenium WebElement in the provided timeout or raise an error …

def get_all_attributes(self) -> dict

Inherited from: XPathElement.get_all_attributes

Return a dictionary containing all of the attributes of an element.

def get_attribute(self, name)

Inherited from: XPathElement.get_attribute

Returns the attribute of the name provided.

def get_property(self, value: str) -> Any

Inherited from: XPathElement.get_property

Get the property of the element …

def is_displayed(self)

Inherited from: XPathElement.is_displayed

Returns true if the Element is displayed else false.

def is_invisible(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.is_invisible

Return true if the webelement is invisible on the page within the time (seconds) provided …

def is_visible(self, timeout: Union[int, NoneType] = None) -> bool

Inherited from: XPathElement.is_visible

Return true if the webelement is visible on the page in the time (seconds) provided …

class Select (webdriver:  = None, timeout: int = 5, xpath: str = '', **kwargs)

Interact with