Conditions | 1 |
Paths | 1 |
Total Lines | 19 |
Code Lines | 13 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
38 | public function save(UnitTester $I) |
||
39 | { |
||
40 | $creditWorklog = new CreditWorkLog(); |
||
41 | $creditWorklog->process_id = 4; // current stage_id = 7 |
||
42 | $creditWorklog->stage_id = 4; |
||
43 | $I->expectException( |
||
44 | ForbiddenHttpException::class, |
||
45 | function () use ($creditWorklog) { |
||
46 | $creditWorklog->save(); |
||
47 | } |
||
48 | ); |
||
49 | |||
50 | $auth = Yii::$app->authManager; |
||
51 | $adminRole = $auth->getRole('admin'); |
||
52 | $auth->assign($adminRole, 1); |
||
53 | Yii::$app->user->login(User::findOne(1)); |
||
54 | |||
55 | $I->assertTrue($creditWorklog->save()); |
||
56 | $auth->revoke($adminRole, 1); |
||
57 | } |
||
59 |
The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g.
excluded_paths: ["lib/*"]
, you can move it to the dependency path list as follows:For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths