mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-02-25 18:45:27 -06:00
Fixed some errors. Debug tests.
This commit is contained in:
parent
ba5db2c15f
commit
f72a8c5c06
@ -18,4 +18,4 @@ install:
|
|||||||
- php artisan migrate --seed
|
- php artisan migrate --seed
|
||||||
|
|
||||||
script:
|
script:
|
||||||
- phpunit
|
- phpunit --debug
|
||||||
|
@ -904,21 +904,18 @@ class TestData
|
|||||||
* @param User $user
|
* @param User $user
|
||||||
* @param $name
|
* @param $name
|
||||||
*
|
*
|
||||||
* @return Account|null
|
* @return Account
|
||||||
*/
|
*/
|
||||||
public static function findAccount(User $user, string $name)
|
public static function findAccount(User $user, string $name): Account
|
||||||
{
|
{
|
||||||
/** @var Account $account */
|
/** @var Account $account */
|
||||||
foreach ($user->accounts()->get() as $account) {
|
foreach ($user->accounts()->get() as $account) {
|
||||||
if ($account->name == $name) {
|
if ($account->name == $name) {
|
||||||
//Log::debug('Trying to find "' . $name . '" in "' . $account->name . '", and found it!');
|
|
||||||
|
|
||||||
return $account;
|
return $account;
|
||||||
}
|
}
|
||||||
//Log::debug('Trying to find "' . $name . '" in "' . $account->name . '".');
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return null;
|
return new Account;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user