Moodle PHP Documentation 4.4
Moodle 4.4.1 (Build: 20240610) (db07c09afc5)
|
Log in log out steps definitions. More...
Public Member Functions | |
getSession ($name=null) | |
Returns the Mink session. | |
i_log_in_as (string $username, moodle_url $wantsurl=null) | |
Logs in the user. | |
i_log_out () | |
Logs out of the system. | |
Public Attributes | |
const | PAGE_READY_JS |
The JS code to check that the page is ready. | |
Log in log out steps definitions.
|
inherited |
Returns the Mink session.
string | null | $name | name of the session OR active session will be used |
Behat\Mink\Session |
Implemented in behat_form_field.
behat_auth::i_log_in_as | ( | string | $username, |
moodle_url | $wantsurl = null ) |
Logs in the user.
There should exist a user with the same value as username and password.
@Given /^I log in as "(?P<username_string>(?:[^"]|::")*)"$/ @Given I am logged in as :username
string | $username | the user to log in as. |
moodle_url | null | $wantsurl | optional, URL to go to after logging in. |
behat_auth::i_log_out | ( | ) |
Logs out of the system.
@Given /^I log out$/ @Given I am not logged in
|
inherited |
The JS code to check that the page is ready.
The document must be complete and either M.util.pending_js must be empty, or it must not be defined at all.