Search moodle.org's
Developer Documentation

See Release Notes

  • Bug fixes for general core bugs in 4.0.x will end 8 May 2023 (12 months).
  • Bug fixes for security issues in 4.0.x will end 13 November 2023 (18 months).
  • PHP version: minimum PHP 7.3.0 Note: the minimum PHP version has increased since Moodle 3.10. PHP 7.4.x is also supported.

Differences Between: [Versions 310 and 400] [Versions 311 and 400] [Versions 39 and 400] [Versions 400 and 401] [Versions 400 and 402] [Versions 400 and 403]

Steps definitions to open and close action menus.

Copyright: 2016 Damyon Wiese
License: http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
File Size: 204 lines (8 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 1 file
 lib/behat/behat_base.php

Defines 1 class


Class: behat_action_menu  - X-Ref

Steps definitions to open and close action menus.

i_open_the_action_menu_in($element, $selectortype)   X-Ref
Open the action menu in

return: void
param: string $element
param: string $selector

i_choose_in_the_open_action_menu($menuitemstring)   X-Ref
When an action menu is open, follow one of the items in it.

return: void
param: string $linkstring

i_choose_in_the_named_menu(string $item, string $actionmenu)   X-Ref
Select a specific item in an action menu.

param: string $item The item to choose
param: string $actionmenu The text used in the description of the action menu

i_choose_in_the_named_menu_in_container(string $item, string $actionmenu, $locator, $selector)   X-Ref
Select a specific item in an action menu within a container.

param: string $item The item to choose
param: string $actionmenu The text used in the description of the action menu
param: string|NodeElement $locator The identifer used for the container
param: string $selector The type of container to locate

select_item_in_action_menu(string $item, NodeElement $menu)   X-Ref
Select an item in the specified menu.

Note: This step does work both with, and without, JavaScript.

param: string $item Item string value
param: NodeElement $menu The menu NodeElement to select from

item_should_not_exist(string $item, string $actionmenu)   X-Ref
The action menu item should not exist.

param: string $item The item to check
param: string $actionmenu The text used in the description of the action menu

item_should_not_exist_in_the(string $item, string $actionmenu, $locator, $selector)   X-Ref
The action menu item should not exist within a container.

param: string $item The item to check
param: string $actionmenu The text used in the description of the action menu
param: string|NodeElement $locator The identifer used for the container
param: string $selector The type of container to locate

item_should_exist(string $item, string $actionmenu)   X-Ref
The action menu item should exist.

param: string $item The item to check
param: string $actionmenu The text used in the description of the action menu

item_should_exist_in_the(string $item, string $actionmenu, $locator, $selector)   X-Ref
The action menu item should exist within a container.

param: string $item The item to check
param: string $actionmenu The text used in the description of the action menu
param: string|NodeElement $locator The identifer used for the container
param: string $selector The type of container to locate