PHP Class Codeception\Module\WordPress

Inheritance: extends Codeception\Lib\Framework, implements Codeception\Lib\Interfaces\DependsOnModule
Afficher le fichier Open project: lucatume/wp-browser

Méthodes publiques

Свойство Type Description
$client tad\WPBrowser\Connector\WordPress

Protected Properties

Свойство Type Description
$adminPath string
$config array
$dependencyMessage string
$isMockRequest boolean
$lastRequestWasAdmin boolean
$requiredFields array
$siteUrl string
$wpdbModule WPDb

Méthodes publiques

Méthode Description
__construct ( Codeception\Lib\ModuleContainer $moduleContainer, array $config = [], WordPress $client = null ) WordPress constructor.
_after ( Codeception\TestInterface $test )
_afterStep ( Codeception\Step $step )
_afterSuite ( )
_before ( Codeception\TestInterface $test )
_beforeStep ( Codeception\Step $step )
_beforeSuite ( $settings = [] )
_cleanup ( )
_depends ( ) : array Specifies class or module which is required for current one.
_failed ( Codeception\TestInterface $test, $fail )
_initialize ( )
_inject ( WPDb $wpdbModule )
_isMockRequest ( $isMockRequest = false )
_lastRequestWasAdmin ( )
_setClient ( $client )
amEditingPostWithId ( $id )
amOnAdminAjaxPage ( )
amOnAdminPage ( $page )
amOnCronPage ( )
amOnPage ( string $page ) : null | string
getInternalDomains ( ) : array Returns a list of recognized domain names
loginAs ( $user, $password )
loginAsAdmin ( )
setAdminPath ( $adminPath )

Méthodes protégées

Méthode Description
getAbsoluteUrlFor ( $uri )

Private Methods

Méthode Description
ensureWpRoot ( )
isAdminPageRequest ( $page )
preparePage ( $page ) : string
setRequestType ( $page )
setupClient ( $siteDomain )
untrailslashIt ( $path ) : mixed

Method Details

__construct() public méthode

WordPress constructor.
public __construct ( Codeception\Lib\ModuleContainer $moduleContainer, array $config = [], WordPress $client = null )
$moduleContainer Codeception\Lib\ModuleContainer
$config array
$client tad\WPBrowser\Connector\WordPress

_after() public méthode

public _after ( Codeception\TestInterface $test )
$test Codeception\TestInterface

_afterStep() public méthode

public _afterStep ( Codeception\Step $step )
$step Codeception\Step

_afterSuite() public méthode

public _afterSuite ( )

_before() public méthode

public _before ( Codeception\TestInterface $test )
$test Codeception\TestInterface

_beforeStep() public méthode

public _beforeStep ( Codeception\Step $step )
$step Codeception\Step

_beforeSuite() public méthode

public _beforeSuite ( $settings = [] )

_cleanup() public méthode

public _cleanup ( )

_depends() public méthode

THis method should return array with key as class name and value as error message [className => errorMessage]
public _depends ( ) : array
Résultat array

_failed() public méthode

public _failed ( Codeception\TestInterface $test, $fail )
$test Codeception\TestInterface

_initialize() public méthode

public _initialize ( )

_inject() public méthode

public _inject ( WPDb $wpdbModule )
$wpdbModule WPDb

_isMockRequest() public méthode

public _isMockRequest ( $isMockRequest = false )

_lastRequestWasAdmin() public méthode

_setClient() public méthode

public _setClient ( $client )

amEditingPostWithId() public méthode

public amEditingPostWithId ( $id )

amOnAdminAjaxPage() public méthode

public amOnAdminAjaxPage ( )

amOnAdminPage() public méthode

public amOnAdminPage ( $page )

amOnCronPage() public méthode

public amOnCronPage ( )

amOnPage() public méthode

public amOnPage ( string $page ) : null | string
$page string The relative path to a page.
Résultat null | string

getAbsoluteUrlFor() protected méthode

protected getAbsoluteUrlFor ( $uri )

getInternalDomains() public méthode

Returns a list of recognized domain names
public getInternalDomains ( ) : array
Résultat array

loginAs() public méthode

public loginAs ( $user, $password )

loginAsAdmin() public méthode

public loginAsAdmin ( )

setAdminPath() public méthode

public setAdminPath ( $adminPath )

Property Details

$adminPath protected_oe property

protected string $adminPath
Résultat string

$client public_oe property

public WordPress,tad\WPBrowser\Connector $client
Résultat tad\WPBrowser\Connector\WordPress

$config protected_oe property

protected array $config
Résultat array

$dependencyMessage protected_oe property

protected string $dependencyMessage
Résultat string

$isMockRequest protected_oe property

protected bool $isMockRequest
Résultat boolean

$lastRequestWasAdmin protected_oe property

protected bool $lastRequestWasAdmin
Résultat boolean

$requiredFields protected_oe property

protected array $requiredFields
Résultat array

$siteUrl protected_oe property

protected string $siteUrl
Résultat string

$wpdbModule protected_oe property

protected WPDb,Codeception\Module $wpdbModule
Résultat WPDb