Свойство | Тип | Описание | |
---|---|---|---|
$actionsCallbacks | array | this is an array of callbacks. Each callback is a single set of actions to execute the story. Each callback is an alternative way to execute the story. Each callback is meant to be equivalent; ie they achieve the same thing, just in different ways. If any of the callbacks has different outcomes, then they belong in separate user stories. NO EXCEPTIONS. This is a fundamental assumption of Storyplayer; ignore it, and Storyplayer's no use to you! | |
$category | string | the category that this story belongs to | |
$compatibleVersion | integer | you HAVE to set this in your story, otherwise we will skip your story | |
$deviceSetupCallback | array | the function that provides any story-specific setup work that happens when we start a device | |
$deviceTeardownCallback | array | the function that provides any story-specific teardown work that happens just before we stop a device | |
$group | array |
the group that this story belongs to | |
$hintsCallback | callable | the function that provides hints about how this story changes the state of the system or user | |
$name | string | the name of this story | |
$params | array | the parameters that get passed into virtual machines et al, and which can be overridden on the command-line | |
$parserTrees | array | the raw parser tree of this story, and of any templates that we use | |
$perPhaseSetupCallback | array | the function that provides any story-specific setup work that happens before each phase of the test | |
$perPhaseTeardownCallback | array | the function that provides any story-specific teardown work that happens at the end of each phase of the test | |
$persistDevice | boolean | does the story want the test device kept open between phases? | |
$postTestInspectionCallback | array | the callback used to see if the action *did* change the state of the system under test | |
$preTestInspectionCallback | array | the callback used to remember the state of the system *before* the action occurs | |
$preTestPredictionCallback | array | the callback that dynamically determines in advance whether the story actions should succeed or fail | |
$reportTestResultsCallback | array | the callback that dynamically determines afterwards whether or not the story actions actually did succeed | |
$requiredTestEnvRoles | array | a list of the roles that the test environment must have defined, otherwise we cannot run | |
$roleChangesCallback | array | the function that provides information about how this story has changed the state of the system or user | |
$storyFilename | string | the file that contains the story | |
$storyResult | what happened to this story? | ||
$storyTemplates | array | a list of the StoryTemplates that this story is based on. can be empty | |
$testCanRunCheckCallback | array | the function that checks to see if the test should run at all, or should be skipped | |
$testSetupCallback | array | the function that provides any story-specific setup work | |
$testTeardownCallback | array | the function that provides any story-specific teardown action | |
$whitelistedEnvironments | by default, a story is allowed to run on all environments, *but* if an environment's config sets 'mustBeWhitelisted' to TRUE, then the story is only allowed to run on that environment if the story declares itself safe to run we believe that this is the safest approach to handling those stories that simply aren't safe to run absolutely everywhere |
Метод | Описание | |
---|---|---|
__toString ( ) : string | return a string representation of the story, for things like logging | |
addAction ( $newCallback ) : void | ||
addActions ( $newCallback ) : void | ||
addDeviceSetup ( $newCallback ) : void | ||
addDeviceTeardown ( $newCallback ) : void | ||
addHints ( $newCallback ) : void | ||
addPerPhaseSetup ( $newCallback ) : void | ||
addPerPhaseTeardown ( $newCallback ) : void | ||
addPostTestInspection ( $newCallback ) : void | ||
addPreTestInspection ( $newCallback ) : void | ||
addPreTestPrediction ( $newCallback ) : void | ||
addTestCanRunCheck ( $newCallback ) : void | ||
addTestEnvironmentSetup ( $newCallback ) | ||
addTestEnvironmentTeardown ( $newCallback ) | ||
addTestSetup ( $newCallback ) | ||
addTestTeardown ( $newCallback ) : void | ||
addValidRole ( $role ) | -------------------------------------------------------------------- | |
andOn ( $envName ) : |
||
andValidRole ( $role ) | Synonym for addValidRole() | |
basedOn ( |
set up any templated methods from a predefined class | |
called ( $userStoryText ) : |
||
determineStoryFilename ( ) : void | ||
generateGroup ( ) : |
Set the group name as the file system path of the directory where the test is located | |
generateName ( ) : |
Set the name as the filename of the test | |
getCategory ( ) : string | Get the category that this story belongs to | |
getDeviceSetup ( ) : array | get the callback for device setup work | |
getDeviceTeardown ( ) : array | get the callback for device teardown work | |
getGroup ( ) : array |
Get the group that this story belongs to | |
getGroupAsString ( ) : string | return the story's group as a printable string | |
getHints ( ) : callable | get the hints callback | |
getName ( ) : string | Get the name of this story | |
getOneAction ( ) : callable | pick one action at random, and return it to the caller | |
getParams ( ) : array | ||
getPerPhaseSetup ( ) : array | get the callback for per-phase setup work | |
getPerPhaseTeardown ( ) : array | get the callback for per-phase teardown work | |
getPersistDevice ( ) : boolean | does this story want to keep the web browser open between phases? | |
getPostTestInspection ( ) : array | get the callback to use to work out the test results | |
getPreTestInspection ( ) : array | get the callback to use to perform the preflight checkpoint | |
getPreTestPrediction ( ) : array | get the callback to use to perform the preflight checks | |
getRequiredStoryplayerVersion ( ) : integer | ||
getRequiredTestEnvironmentRoles ( ) : array | ||
getResult ( ) : |
||
getRoleChanges ( ) | get the role changes callback | |
getStoryFilename ( ) : string | ||
getStoryTemplates ( ) : array |
get a list of the templates that this story is based on, in order or precedence | |
getTestCanRunCheck ( ) : array | get the callback which allows the story to be skipped | |
getTestSetup ( ) : array | get the callback for per-story setup work | |
getTestTeardown ( ) : array | get the callback for post-story teardown work | |
getWhitelistedEnvironments ( ) : array | ||
hasActions ( ) : boolean | does this story have any actions? | |
hasDeviceSetup ( ) : boolean | do we have a device setup callback? | |
hasDeviceTeardown ( ) : boolean | do we have a device teardown callback? | |
hasHints ( ) : boolean | have any hints been set? | |
hasPerPhaseSetup ( ) : boolean | do we have a per-phase setup callback? | |
hasPerPhaseTeardown ( ) : boolean | do we have a per-phase teardown callback? | |
hasPostTestInspection ( ) : boolean | ||
hasPreTestInspection ( ) : boolean | do we have a callback | |
hasPreTestPrediction ( ) : boolean | do we have a callback | |
hasRole ( $roleName ) | ||
hasRoleChanges ( ) | has the role changes callback been set? | |
hasTestCanRunCheck ( ) : boolean | do we have a 'check story can run' callback? | |
hasTestSetup ( ) : boolean | do we have a pre-story setup callback? | |
hasTestTeardown ( ) : boolean | do we have a post-story teardown callback? | |
inGroup ( array | string $groupName ) : |
which group of tests does this story belong to? | |
requiresStoryplayerVersion ( $version ) : |
||
requiresTestEnvironmentWithRoles ( $roles ) : void | ||
runsOn ( $envName ) : |
||
setCategory ( string $newCategory ) : |
Set the category that this story belongs to | |
setDefaultCallbacks ( ) : void | ||
setGroup ( array |
Set the group that this story belongs to | |
setHints ( $newCallback ) : void | ||
setName ( string $newName ) : |
Set the name of this story | |
setParams ( array $defaults ) | Set the parameters for this story | |
setPersistDevice ( ) | tell Storyplayer to keep the web browser open between test phases | |
setRoleChanges ( $newCallback ) | ||
setTestEnvironmentSetup ( $newCallback ) | -------------------------------------------------------------------- | |
setTestEnvironmentTeardown ( $newCallback ) |
public __toString ( ) : string | ||
Результат | string |
public addPerPhaseTeardown ( $newCallback ) : void | ||
Результат | void |
public addPostTestInspection ( $newCallback ) : void | ||
Результат | void |
public addPreTestInspection ( $newCallback ) : void | ||
Результат | void |
public addPreTestPrediction ( $newCallback ) : void | ||
Результат | void |
public addTestCanRunCheck ( $newCallback ) : void | ||
Результат | void |
public addValidRole ( $role ) |
public basedOn ( |
||
$tmpl | ||
Результат |
public generateGroup ( ) : |
||
Результат | $this for fluent interface |
public generateName ( ) : |
||
Результат | $this for fluent interface |
public getCategory ( ) : string | ||
Результат | string | the category that this story belongs to |
public getDeviceSetup ( ) : array | ||
Результат | array |
public getDeviceTeardown ( ) : array | ||
Результат | array |
public getGroup ( ) : array |
||
Результат | array |
public getGroupAsString ( ) : string | ||
Результат | string |
public getOneAction ( ) : callable | ||
Результат | callable |
public getPerPhaseSetup ( ) : array | ||
Результат | array |
public getPerPhaseTeardown ( ) : array | ||
Результат | array |
public getPersistDevice ( ) : boolean | ||
Результат | boolean |
public getPostTestInspection ( ) : array | ||
Результат | array |
public getPreTestInspection ( ) : array | ||
Результат | array |
public getPreTestPrediction ( ) : array | ||
Результат | array |
public getRequiredStoryplayerVersion ( ) : integer | ||
Результат | integer |
public getRequiredTestEnvironmentRoles ( ) : array | ||
Результат | array |
public getStoryTemplates ( ) : array |
||
Результат | array |
public getTestCanRunCheck ( ) : array | ||
Результат | array |
public getTestSetup ( ) : array | ||
Результат | array |
public getTestTeardown ( ) : array | ||
Результат | array |
public getWhitelistedEnvironments ( ) : array | ||
Результат | array |
public hasActions ( ) : boolean | ||
Результат | boolean | true if this story has any actions |
public hasDeviceSetup ( ) : boolean | ||
Результат | boolean | true if there is a device setup callback |
public hasDeviceTeardown ( ) : boolean | ||
Результат | boolean | true if there is a device teardown callback |
public hasPerPhaseSetup ( ) : boolean | ||
Результат | boolean | true if there is a per-phase setup callback |
public hasPerPhaseTeardown ( ) : boolean | ||
Результат | boolean | true if there is a per-phase teardown callback |
public hasPostTestInspection ( ) : boolean | ||
Результат | boolean |
public hasPreTestInspection ( ) : boolean | ||
Результат | boolean | [description] |
public hasPreTestPrediction ( ) : boolean | ||
Результат | boolean | [description] |
public hasTestCanRunCheck ( ) : boolean | ||
Результат | boolean | true if the callback exists |
public hasTestSetup ( ) : boolean | ||
Результат | boolean | true if there is a pre-story setup callback |
public hasTestTeardown ( ) : boolean | ||
Результат | boolean | true if there is a post-story teardown callback |
public requiresStoryplayerVersion ( $version ) : |
||
Результат |
public requiresTestEnvironmentWithRoles ( $roles ) : void | ||
Результат | void |
public setCategory ( string $newCategory ) : |
||
$newCategory | string | the category that this story belongs to |
Результат | $this |
public setGroup ( array |
||
$newGroup | array |
|
Результат | $this |
public setPersistDevice ( ) |
public setTestEnvironmentSetup ( $newCallback ) |
protected array $actionsCallbacks | ||
Результат | array |
protected string $category | ||
Результат | string |
protected int $compatibleVersion | ||
Результат | integer |
protected array $deviceSetupCallback | ||
Результат | array |
protected array $deviceTeardownCallback | ||
Результат | array |
protected array |
||
Результат | array |
protected callable $hintsCallback | ||
Результат | callable |
protected array $params | ||
Результат | array |
protected array $parserTrees | ||
Результат | array |
protected array $perPhaseSetupCallback | ||
Результат | array |
protected array $perPhaseTeardownCallback | ||
Результат | array |
protected bool $persistDevice | ||
Результат | boolean |
protected array $postTestInspectionCallback | ||
Результат | array |
protected array $preTestInspectionCallback | ||
Результат | array |
protected array $preTestPredictionCallback | ||
Результат | array |
protected array $reportTestResultsCallback | ||
Результат | array |
protected array $requiredTestEnvRoles | ||
Результат | array |
protected array $roleChangesCallback | ||
Результат | array |
protected string $storyFilename | ||
Результат | string |
protected Story_Result,DataSift\Storyplayer\PlayerLib $storyResult | ||
Результат |
protected array $storyTemplates | ||
Результат | array |
protected array $testCanRunCheckCallback | ||
Результат | array |
protected array $testSetupCallback | ||
Результат | array |
protected array $testTeardownCallback | ||
Результат | array |
protected $whitelistedEnvironments |