HEX
Server: Apache
System: Linux webm010.cluster103.gra.hosting.ovh.net 6.18.42-ovh-vps-grsec-zfs+ #1 SMP PREEMPT_DYNAMIC Wed Aug 5 15:59:48 CEST 2026 x86_64
User: iestorre (46869)
PHP: 8.0.30
Disabled: _dyuweyrj4,_dyuweyrj4r,dl
Upload Files
File: /home/iestorre/moodleAW/moodle506/admin/tool/behat/tests/behat/basic_actions.feature
@tool @tool_behat
Feature: Page contents assertions
  In order to write good tests
  As a tests writer
  I need to check the page contents

  @javascript
  Scenario: Basic contents assertions
    Given I log in as "admin"
    And I am on homepage
    And I expand "Users" node
    And I follow "Groups"
    And I press "Create group"
    And I fill the moodle form with:
      | Group name | I'm the name |
      | Group description | I'm the description |
    And I press "Save changes"
    When I follow "Overview"
    And I wait until the page is ready
    And I wait "2" seconds
    And I hover "#region-main .generaltable td span" "css_element"
    Then I should see "I'm the description"
    And "Grouping" "select" in the "region-main" "region" should be visible
    And "Group" "select" should be visible
    And "Messaging" "link" in the "Administration" "block" should not be visible
    And "Change password" "link" should not be visible
    And I should see "Filter groups by"
    And I should not see "Filter groupssss by"
    And I should see "Group members" in the "#region-main table th.c1" "css_element"
    And I should not see "Group membersssss" in the "#region-main table th.c1" "css_element"
    And I follow "Groups"
    And the "#groupeditform #showcreateorphangroupform" "css_element" should be enabled
    And the "#groupeditform #showeditgroupsettingsform" "css_element" should be disabled

  @javascript
  Scenario: Locators inside specific DOM nodes using CSS selectors
    Given the following "courses" exists:
      | fullname | shortname | category |
      | Course 1 | C1 | 0 |
    And I log in as "admin"
    And I follow "Course 1"
    When I dock "Administration" block
    Then I should not see "Question bank" in the ".block-region" "css_element"
    And I click on "//div[@id='dock']/descendant::h2[normalize-space(.)='Administration']" "xpath_element"

  @javascript
  Scenario: Locators inside specific DOM nodes using XPath
    Given the following "courses" exists:
      | fullname | shortname | category |
      | Course 1 | C1 | 0 |
    And I log in as "admin"
    When I dock "Administration" block
    Then I should not see "Turn editing on" in the ".block-region" "css_element"