PHP Class Codeception\Module\WPBootstrapper

Bootstraps a WordPress installation to access its functions.
Inheritance: extends Codeception\Module, use trait WPSugarMethods
Show file Open project: lucatume/wp-browser

Protected Properties

Property Type Description
$config array
$globalSnapshotSkipKeys array
$globalStateSnapshot SebastianBergmann\GlobalState\Snapshot
$requiredFields array
$restorer SebastianBergmann\GlobalState\Restorer
$superGlobalArrays array
$wp tad\WPBrowser\Adapters\WP
$wpLoadPath The absolute path to the target WordPress installation wp-load.php file.

Public Methods

Method Description
__construct ( Codeception\Lib\ModuleContainer $moduleContainer, $config, SebastianBergmann\GlobalState\Restorer $restorer = null, tad\WPBrowser\Adapters\WP $wp = null )
_initialize ( )
bootstrapWp ( )
getSnapshot ( )
unsetGlobalClosures ( )

Protected Methods

Method Description
isClosure ( $value )
nullClosures ( $value, $level )
setupSuperglobalArrays ( )

Private Methods

Method Description
restoreAllGlobals ( )
restoreWpdbConnection ( )

Method Details

__construct() public method

public __construct ( Codeception\Lib\ModuleContainer $moduleContainer, $config, SebastianBergmann\GlobalState\Restorer $restorer = null, tad\WPBrowser\Adapters\WP $wp = null )
$moduleContainer Codeception\Lib\ModuleContainer
$restorer SebastianBergmann\GlobalState\Restorer
$wp tad\WPBrowser\Adapters\WP

_initialize() public method

public _initialize ( )

bootstrapWp() public method

public bootstrapWp ( )

getSnapshot() public method

public getSnapshot ( )

isClosure() protected method

protected isClosure ( $value )

nullClosures() protected method

protected nullClosures ( $value, $level )

setupSuperglobalArrays() protected method

protected setupSuperglobalArrays ( )

unsetGlobalClosures() public method

public unsetGlobalClosures ( )

Property Details

$config protected property

protected array $config
return array

$globalSnapshotSkipKeys protected property

protected array $globalSnapshotSkipKeys
return array

$globalStateSnapshot protected property

protected Snapshot,SebastianBergmann\GlobalState $globalStateSnapshot
return SebastianBergmann\GlobalState\Snapshot

$requiredFields protected property

protected array $requiredFields
return array

$restorer protected property

protected Restorer,SebastianBergmann\GlobalState $restorer
return SebastianBergmann\GlobalState\Restorer

$superGlobalArrays protected property

protected array $superGlobalArrays
return array

$wp protected property

protected WP,tad\WPBrowser\Adapters $wp
return tad\WPBrowser\Adapters\WP

$wpLoadPath protected property

The absolute path to the target WordPress installation wp-load.php file.
protected $wpLoadPath