Moodle PHP Documentation 4.2
Moodle 4.2.8 (Build: 20240610) (2d41ac46f45)
behat_selectors Class Reference

Moodle selectors manager. More...

Static Public Member Functions

static get_allowed_selectors ()
 Allowed selectors getter.
 
static get_allowed_text_selectors ()
 Allowed text selectors getter.
 
static get_behat_selector ($selectortype, $element, Behat\Mink\Session $session)
 Returns the behat selector and locator for a given moodle selector and locator.
 
static normalise_named_selector (string $selector, string $locator)
 Normalise the selector and locator for a named partial.
 
static transform_find_for_field (behat_base $context, string $label, Element $container)
 Transform the selector for a field.
 

Detailed Description

Moodle selectors manager.

License
http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later

Member Function Documentation

◆ get_allowed_selectors()

static behat_selectors::get_allowed_selectors ( )
static

Allowed selectors getter.

Return values
array

◆ get_allowed_text_selectors()

static behat_selectors::get_allowed_text_selectors ( )
static

Allowed text selectors getter.

Return values
array

◆ get_behat_selector()

static behat_selectors::get_behat_selector ( $selectortype,
$element,
Behat\Mink\Session $session )
static

Returns the behat selector and locator for a given moodle selector and locator.

Parameters
string$selectortypeThe moodle selector type, which includes moodle selectors
string$elementThe locator we look for in that kind of selector
Session$sessionThe Mink opened session
Return values
arrayContains the selector and the locator expected by Mink.

◆ normalise_named_selector()

static behat_selectors::normalise_named_selector ( string $selector,
string $locator )
static

Normalise the selector and locator for a named partial.

Parameters
string$selectorThe selector name
string$locatorThe value to normalise
Return values
array

◆ transform_find_for_field()

static behat_selectors::transform_find_for_field ( behat_base $context,
string $label,
Element $container )
static

Transform the selector for a field.

Parameters
string$labelThe label to find
Element$containerThe container to look within
Return values
arrayThe selector, locator, and container to search within

The documentation for this class was generated from the following file: