E2E_Shimmy_LifecycleTest
extends TestCase
in package
implements
EndToEndInterface
Enable, disable, and uninstall an extension. Ensure that various local example is enabled and disabled appropriately.
The substantive assertions are split across various files in tests/mixins/*.php
.
Tags
Table of Contents
Interfaces
- EndToEndInterface
- Interface EndToEndInterface
Properties
- $mixinTests : array<string|int, mixed>
Methods
- setUpBeforeClass() : void
- testLifecycleWithLocalFunctions() : void
- Install and uninstall the extension. Ensure that various mixins+artifacts work correctly.
- testLifecycleWithSubprocesses() : void
- Install and uninstall the extension. Ensure that various mixins+artifacts work correctly.
- createCvWithLocalFunctions() : mixed
- createCvWithSubprocesses() : mixed
- getPath() : string
- runMethods() : void
- setUp() : void
- runLifecycle() : void
Properties
$mixinTests
protected
array<string|int, mixed>
$mixinTests
Methods
setUpBeforeClass()
public
static setUpBeforeClass() : void
testLifecycleWithLocalFunctions()
Install and uninstall the extension. Ensure that various mixins+artifacts work correctly.
public
testLifecycleWithLocalFunctions() : void
This interacts with Civi by calling local PHP functions (civicrm_api3(
and civicrm_api4()
).
This style of interaction reveals whether the install/uninstall mechanics have data-leaks that
may cause subtle/buggy interactions during the transitions.
testLifecycleWithSubprocesses()
Install and uninstall the extension. Ensure that various mixins+artifacts work correctly.
public
testLifecycleWithSubprocesses() : void
This interacts with Civi by running many subprocesses (cv api3
and cv api4
commands).
This style of interaction is a better representation of how day-to-day sysadmin works.
createCvWithLocalFunctions()
protected
createCvWithLocalFunctions() : mixed
createCvWithSubprocesses()
protected
createCvWithSubprocesses() : mixed
getPath()
protected
static getPath([mixed $suffix = '' ]) : string
Parameters
- $suffix : mixed = ''
Return values
stringrunMethods()
protected
runMethods(string $method, mixed ...$args) : void
Parameters
- $method : string
- $args : mixed
setUp()
protected
setUp() : void
runLifecycle()
private
runLifecycle(object $cv) : void
Parameters
- $cv : object
-
The
$cv
object is (roughly speaking) a wrapper for callingcv
. It has method bindings for$cv->api3()
and$cv->api4()
. Different variations of$cv
may be supplied - they will execute$cv->api3()
and$cv->api4()
in slightly different ways.