Skip to content

Commit

Permalink
Merge pull request #31 from florianv/fixes
Browse files Browse the repository at this point in the history
Test configuration and documentation fixes
  • Loading branch information
florianv authored Jun 3, 2017
2 parents 7daaad4 + ea03a8d commit 6caabda
Show file tree
Hide file tree
Showing 6 changed files with 34 additions and 4 deletions.
17 changes: 17 additions & 0 deletions .php_cs.dist
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<?php
return PhpCsFixer\Config::create()
->setRules(array(
'@Symfony' => true,
'@Symfony:risky' => true,
'array_syntax' => array('syntax' => 'short'),
'no_unreachable_default_argument_value' => false,
'heredoc_to_nowdoc' => false,
'phpdoc_annotation_without_dot' => false,
))
->setRiskyAllowed(true)
->setFinder(
PhpCsFixer\Finder::create()
->in(__DIR__.'/src')
->in(__DIR__.'/tests')
)
;
1 change: 0 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ php:
- 5.6
- 7.0
- 7.1
- hhvm

sudo: false

Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,7 @@ Here is the list of the currently implemented services.
| [Central Bank of the Czech Republic](http://www.cnb.cz) | * | CZK | No |
| [Russian Central Bank](http://http://www.cbr.ru) | * | RUB | Yes |
| [currencylayer](https://currencylayer.com) | USD (free), * (paid) | * | Yes |
| Array | * | * | Yes |

## Credits

Expand Down
15 changes: 14 additions & 1 deletion doc/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,20 @@ Here is the complete list of supported services and their possible configuration
'google' => true,
'national_bank_of_romania' => true,
'open_exchange_rates' => ['app_id' => 'secret', 'enterprise' => false],
'array' => [['EUR/USD' => new ExchangeRate('1.5')]],
'array' => [
[
'EUR/USD' => new ExchangeRate('1.1'),
'EUR/GBP' => 1.5
],
[
'2017-01-01' => [
'EUR/USD' => new ExchangeRate('1.5')
],
'2017-01-03' => [
'EUR/GBP' => 1.3
],
]
],
'webservicex' => true,
'xignite' => ['token' => 'token'],
'yahoo' => true,
Expand Down
2 changes: 1 addition & 1 deletion src/SwapServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -210,6 +210,6 @@ private function getServiceClass($name)
*/
private function getConfigPath($path = '')
{
return app()->basePath() . '/config' . ($path ? '/' . $path : $path);
return app()->basePath().'/config'.($path ? '/'.$path : $path);
}
}
2 changes: 1 addition & 1 deletion tests/SwapServiceProviderTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ public function testAllServices()
'webservicex' => true,
'xignite' => ['token' => 'token'],
'yahoo' => true,
'russian_central_bank' => true
'russian_central_bank' => true,
]);

$this->assertInstanceOf(Chain::class, $this->app['swap.chain']);
Expand Down

0 comments on commit 6caabda

Please sign in to comment.