PHP Class Codeception\Module\WPBrowser

Inheritance: extends Codeception\Module\PhpBrowser, use trait WPBrowserMethods
Show file Open project: lucatume/wp-browser

Protected Properties

Property Type Description
$adminPath [type] The admin absolute URL.
$loginUrl string The login screen absolute URL
$pluginsPath string The plugin screen absolute URL
$requiredFields array The module required fields, to be set in the suite .yml configuration file.

Public Methods

Method Description
_initialize ( ) : void Initializes the module setting the properties values.
activatePlugin ( string $pluginSlug ) : void In the plugin administration screen activates a plugin clicking the "Activate" link.
deactivatePlugin ( string $pluginSlug ) : void In the plugin administration screen deactivates a plugin clicking the "Deactivate" link.
grabCookiesWithPattern ( string $cookiePattern ) : Cookie | null Returns all the cookies whose name matches a regex pattern.

Protected Methods

Method Description
configBackCompat ( )
validateConfig ( )

Method Details

_initialize() public method

Initializes the module setting the properties values.
public _initialize ( ) : void
return void

activatePlugin() public method

The method will presume the browser is in the plugin screen already.
public activatePlugin ( string $pluginSlug ) : void
$pluginSlug string The plugin slug, like "hello-dolly".
return void

configBackCompat() protected method

protected configBackCompat ( )

deactivatePlugin() public method

The method will presume the browser is in the plugin screen already.
public deactivatePlugin ( string $pluginSlug ) : void
$pluginSlug string The plugin slug, like "hello-dolly".
return void

grabCookiesWithPattern() public method

Returns all the cookies whose name matches a regex pattern.
public grabCookiesWithPattern ( string $cookiePattern ) : Cookie | null
$cookiePattern string
return Symfony\Component\BrowserKit\Cookie | null

validateConfig() protected method

protected validateConfig ( )

Property Details

$adminPath protected property

The admin absolute URL.
protected [type] $adminPath
return [type]

$loginUrl protected property

The login screen absolute URL
protected string $loginUrl
return string

$pluginsPath protected property

The plugin screen absolute URL
protected string $pluginsPath
return string

$requiredFields protected property

The module required fields, to be set in the suite .yml configuration file.
protected array $requiredFields
return array