Conditions | 1 |
Paths | 1 |
Total Lines | 11 |
Code Lines | 5 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
17 | public function testCreateStripeAccountObject() |
||
18 | { |
||
19 | // get the logged in user (create one if no one is logged in) |
||
20 | $user = $this->getTestingUser(); |
||
21 | |||
22 | // create stripe account for this user |
||
23 | $createStripeAccountAction = App::make(CreateStripeAccountObjectTask::class); |
||
24 | $stripeAccount = $createStripeAccountAction->run($user, 'cus_8mBD5S1SoyD4zL', 'card_18Uck6KFvMcBUkvQorbBkYhR', 'credit', '4242', 'WsNM4K8puHbdS2VP'); |
||
|
|||
25 | |||
26 | $this->seeInDatabase('stripe_accounts', ['user_id' => $user->id]); |
||
27 | } |
||
28 | |||
30 |
This check looks for variable assignements that are either overwritten by other assignments or where the variable is not used subsequently.
Both the
$myVar
assignment in line 1 and the$higher
assignment in line 2 are dead. The first because$myVar
is never used and the second because$higher
is always overwritten for every possible time line.