ILIAS  release_6 Revision v6.24-5-g0c8bfefb3b8
Test_ilDatabaseUpdateSteps Class Reference
+ Inheritance diagram for Test_ilDatabaseUpdateSteps:
+ Collaboration diagram for Test_ilDatabaseUpdateSteps:

Public Member Functions

 step_1 (\ilDBInterface $db)
 
 step_4 (\ilDBInterface $db)
 
 step_2 (\ilDBInterface $db)
 
 getAdditionalPreconditionsForStep (int $num)
 Get preconditions for steps. More...
 
 _getSteps ()
 
- Public Member Functions inherited from ilDatabaseUpdateSteps
 __construct (Objective $base)
 
 getAdditionalPreconditionsForStep (int $num)
 Get preconditions for steps. More...
 
 getHash ()
 The hash for the objective is calculated over the classname and the steps that are contained. More...
 
 getLabel ()
 Get a label that describes this objective. More...
 
 isNotable ()
 @inheritdocs More...
 
 getPreconditions (Environment $environment)
 @inheritdocs More...
 
 achieve (Environment $environment)
 @inheritdocs More...
 
 getStep (int $num, int $finished=0)
 Get a database update step. More...
 
 getLatestStepNum ()
 Get the number of latest database step in this class. More...
 
 getHash ()
 Get a hash for this objective. More...
 
 getLabel ()
 Get a label that describes this objective. More...
 
 isNotable ()
 Get to know if this is an interesting objective for a human. More...
 
 getPreconditions (Environment $environment)
 Objectives might depend on other objectives. More...
 
 achieve (Environment $environment)
 Objectives can be achieved. More...
 

Data Fields

 $called = []
 
 $step_2_precondition = null
 
- Data Fields inherited from ilDatabaseUpdateSteps
const STEP_METHOD_PREFIX = "step_"
 

Additional Inherited Members

- Protected Member Functions inherited from ilDatabaseUpdateSteps
 getSteps ()
 Get the numbers of the steps in this class. More...
 
- Protected Attributes inherited from ilDatabaseUpdateSteps
 $steps = null
 
 $base
 

Detailed Description

Definition at line 12 of file ilDatabaseUpdateStepsTest.php.

Member Function Documentation

◆ _getSteps()

Test_ilDatabaseUpdateSteps::_getSteps ( )

Definition at line 51 of file ilDatabaseUpdateStepsTest.php.

51 : array
52 {
53 return $this->getSteps();
54 }
getSteps()
Get the numbers of the steps in this class.

References ilDatabaseUpdateSteps\getSteps().

+ Here is the call graph for this function:

◆ getAdditionalPreconditionsForStep()

Test_ilDatabaseUpdateSteps::getAdditionalPreconditionsForStep ( int  $num)

Get preconditions for steps.

The previous step will automatically be a precondition of every step but will not be returned from this method.

Returns
Objective[]

Reimplemented from ilDatabaseUpdateSteps.

Definition at line 43 of file ilDatabaseUpdateStepsTest.php.

43 : array
44 {
45 if ($this->step_2_precondition && $num === 2) {
47 }
48 return [];
49 }

References $step_2_precondition.

◆ step_1()

Test_ilDatabaseUpdateSteps::step_1 ( \ilDBInterface  $db)

Definition at line 18 of file ilDatabaseUpdateStepsTest.php.

19 {
20 $this->called[] = 1;
21 // Call some function on the interface to check if this step
22 // is really called.
23 $db->connect();
24 }

References ilDBInterface\connect().

+ Here is the call graph for this function:

◆ step_2()

Test_ilDatabaseUpdateSteps::step_2 ( \ilDBInterface  $db)

Definition at line 35 of file ilDatabaseUpdateStepsTest.php.

36 {
37 $this->called[] = 2;
38 // Call some function on the interface to check if this step
39 // is really called.
40 $db->connect();
41 }

References ilDBInterface\connect().

+ Here is the call graph for this function:

◆ step_4()

Test_ilDatabaseUpdateSteps::step_4 ( \ilDBInterface  $db)

Definition at line 27 of file ilDatabaseUpdateStepsTest.php.

28 {
29 $this->called[] = 4;
30 // Call some function on the interface to check if this step
31 // is really called.
32 $db->connect();
33 }

References ilDBInterface\connect().

+ Here is the call graph for this function:

Field Documentation

◆ $called

Test_ilDatabaseUpdateSteps::$called = []

Definition at line 14 of file ilDatabaseUpdateStepsTest.php.

◆ $step_2_precondition

Test_ilDatabaseUpdateSteps::$step_2_precondition = null

Definition at line 16 of file ilDatabaseUpdateStepsTest.php.

Referenced by getAdditionalPreconditionsForStep().


The documentation for this class was generated from the following file: