Improve test coverage.

This commit is contained in:
James Cole
2019-07-31 16:53:09 +02:00
parent 5524941c90
commit 9b574ce7ad
155 changed files with 1890 additions and 2263 deletions

View File

@@ -27,6 +27,7 @@ use FireflyIII\Models\AccountType;
/**
* Trait AccountFilter
* @codeCoverageIgnore
*/
trait AccountFilter
{
@@ -78,10 +79,8 @@ trait AccountFilter
'credit-card' => [AccountType::CREDITCARD],
'creditcard' => [AccountType::CREDITCARD],
'cc' => [AccountType::CREDITCARD],
];
$return = $types[$type] ?? $types['all'];
return $return; // @codeCoverageIgnore
return $types[$type] ?? $types['all'];
}
}

View File

@@ -26,6 +26,7 @@ use Illuminate\Support\Collection;
/**
* Trait ApiSupport
* @codeCoverageIgnore
*/
trait ApiSupport
{

View File

@@ -27,6 +27,7 @@ use FireflyIII\Models\TransactionType;
/**
* Trait TransactionFilter
* @codeCoverageIgnore
*/
trait TransactionFilter
{
@@ -58,9 +59,8 @@ trait TransactionFilter
'specials' => [TransactionType::OPENING_BALANCE, TransactionType::RECONCILIATION,],
'default' => [TransactionType::WITHDRAWAL, TransactionType::DEPOSIT, TransactionType::TRANSFER,],
];
$return = $types[$type] ?? $types['default'];
return $types[$type] ?? $types['default'];
return $return;
}
}