Skip to content

Commit

Permalink
Rename variable from $data to $config
Browse files Browse the repository at this point in the history
  • Loading branch information
r-kujawa committed Jun 24, 2024
1 parent fa19661 commit ebeee27
Showing 1 changed file with 11 additions and 11 deletions.
22 changes: 11 additions & 11 deletions tests/Feature/Console/Config/OrchestrateServiceCommandTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,30 +17,30 @@ class OrchestrateServiceCommandTest extends TestOrchestrateServiceCommand

protected function makeSureProviderExists(ServiceConfig $serviceConfig, Providable $provider)
{
$data = require(config_path(Str::slug($serviceConfig->id).'.php'));
$config = require(config_path(Str::slug($serviceConfig->id).'.php'));

$this->assertIsArray($data['providers']);
$this->assertIsArray($data['providers'][$provider->getId()]);
$this->assertIsArray($config['providers']);
$this->assertIsArray($config['providers'][$provider->getId()]);
$this->assertEquals(
'App\\Services\\'.Str::studly($serviceConfig->id).'\\'.Str::studly($provider->getId()).Str::studly($serviceConfig->id).'Request',
$data['providers'][$provider->getId()]['gateway']
$config['providers'][$provider->getId()]['gateway']
);
}

protected function makeSureAccountExists(ServiceConfig $serviceConfig, Accountable $account)
{
$data = require(config_path(Str::slug($serviceConfig->id).'.php'));
$config = require(config_path(Str::slug($serviceConfig->id).'.php'));

$this->assertIsArray($data['accounts']);
$this->assertIsArray($data['accounts'][$account->getId()]);
$this->assertIsArray($data['accounts'][$account->getId()]['providers']);
$this->assertNotEmpty($data['accounts'][$account->getId()]['providers']);
$this->assertIsArray($config['accounts']);
$this->assertIsArray($config['accounts'][$account->getId()]);
$this->assertIsArray($config['accounts'][$account->getId()]['providers']);
$this->assertNotEmpty($config['accounts'][$account->getId()]['providers']);
}

protected function makeSureProviderIsLinkedToAccount(ServiceConfig $serviceConfig, Providable $provider, Accountable $account)
{
$data = require(config_path(Str::slug($serviceConfig->id).'.php'));
$config = require(config_path(Str::slug($serviceConfig->id).'.php'));

$this->assertIsArray($data['accounts'][$account->getId()]['providers'][$provider->getId()]);
$this->assertIsArray($config['accounts'][$account->getId()]['providers'][$provider->getId()]);
}
}

0 comments on commit ebeee27

Please sign in to comment.