mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-12-12 01:42:32 +00:00
New tests
This commit is contained in:
@@ -182,6 +182,45 @@ trait CollectsValues
|
||||
return $this->getRandomAccount(AccountType::ASSET, $except);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int|null $except
|
||||
*
|
||||
* @return Account
|
||||
*/
|
||||
public function getRandomDebt(?int $except = null): Account
|
||||
{
|
||||
return $this->getRandomAccount(AccountType::DEBT, $except);
|
||||
}
|
||||
/**
|
||||
* @param int|null $except
|
||||
*
|
||||
* @return Account
|
||||
*/
|
||||
public function getRandomLoan(?int $except = null): Account
|
||||
{
|
||||
return $this->getRandomAccount(AccountType::LOAN, $except);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int|null $except
|
||||
*
|
||||
* @return Account
|
||||
*/
|
||||
public function getRandomRevenue(?int $except = null): Account
|
||||
{
|
||||
return $this->getRandomAccount(AccountType::REVENUE, $except);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int|null $except
|
||||
*
|
||||
* @return Account
|
||||
*/
|
||||
public function getRandomExpense(?int $except = null): Account
|
||||
{
|
||||
return $this->getRandomAccount(AccountType::EXPENSE, $except);
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $type
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user