Skip to content

Commit

Permalink
Merge pull request #47 from dragosprotung/master
Browse files Browse the repository at this point in the history
Allow configuring AbstractApi
  • Loading branch information
florianv authored Sep 24, 2021
2 parents 3c788ce + 6cca708 commit 2cfd260
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
11 changes: 11 additions & 0 deletions DependencyInjection/Configuration.php
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,17 @@ public function getConfigTreeBuilder()
->end()
->arrayNode('providers')
->children()
->arrayNode('abstract_api')
->children()
->integerNode('priority')->defaultValue(0)->end()
->scalarNode('api_key')
->treatFalseLike(null)
->treatTrueLike(null)
->isRequired()
->cannotBeEmpty()
->end()
->end()
->end()
->arrayNode('fixer')
->children()
->integerNode('priority')->defaultValue(0)->end()
Expand Down
1 change: 1 addition & 0 deletions Tests/DependencyInjection/ConfigurationTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,7 @@ public function testInvalidCacheConfig(array $cache): void
public function provideValidProvidersConfigs(): array
{
return [
[['abstract_api' => ['api_key' => 'any']]],
[['central_bank_of_czech_republic' => null]],
[['central_bank_of_republic_turkey' => []]],
[['european_central_bank' => null]],
Expand Down

0 comments on commit 2cfd260

Please sign in to comment.