Expand test coverage for bunq.

This commit is contained in:
James Cole
2018-05-25 08:38:15 +02:00
parent 6c9901b919
commit e953becbae
6 changed files with 540 additions and 30 deletions

View File

@@ -81,7 +81,7 @@ class ChooseAccountsHandler implements BunqJobConfigurationInterface
$mapping = $data['account_mapping'] ?? [];
$final = [];
if (\count($accounts) === 0) {
throw new FireflyException('No bunq accounts found. Import cannot continue.');
throw new FireflyException('No bunq accounts found. Import cannot continue.'); // @codeCoverageIgnore
}
if (\count($mapping) === 0) {
$messages = new MessageBag;
@@ -115,7 +115,7 @@ class ChooseAccountsHandler implements BunqJobConfigurationInterface
$config = $this->repository->getConfiguration($this->importJob);
$accounts = $config['accounts'] ?? [];
if (\count($accounts) === 0) {
throw new FireflyException('No bunq accounts found. Import cannot continue.');
throw new FireflyException('No bunq accounts found. Import cannot continue.'); // @codeCoverageIgnore
}
// list the users accounts:
$collection = $this->accountRepository->getAccountsByType([AccountType::ASSET]);
@@ -140,6 +140,8 @@ class ChooseAccountsHandler implements BunqJobConfigurationInterface
}
/**
* @codeCoverageIgnore
*
* Get the view for this stage.
*
* @return string