Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
| Total | |
0.00% |
0 / 6 |
|
0.00% |
0 / 1 |
CRAP | |
0.00% |
0 / 1 |
| ext | |
0.00% |
0 / 6 |
|
0.00% |
0 / 1 |
12 | |
0.00% |
0 / 1 |
| enable_step | |
0.00% |
0 / 6 |
|
0.00% |
0 / 1 |
12 | |||
| 1 | <?php |
| 2 | |
| 3 | namespace vendor3\bar; |
| 4 | |
| 5 | class ext extends \phpbb\extension\base |
| 6 | { |
| 7 | static public $state; |
| 8 | |
| 9 | public function enable_step($old_state) |
| 10 | { |
| 11 | // run 4 steps, then quit |
| 12 | if ($old_state === 4) |
| 13 | { |
| 14 | return false; |
| 15 | } |
| 16 | |
| 17 | if ($old_state === false) |
| 18 | { |
| 19 | $old_state = 0; |
| 20 | } |
| 21 | |
| 22 | self::$state = ++$old_state; |
| 23 | |
| 24 | return self::$state; |
| 25 | } |
| 26 | } |