mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-02-25 18:45:27 -06:00
Improve test coverage.
This commit is contained in:
@@ -46,11 +46,11 @@ use Session;
|
||||
|
||||
/**
|
||||
* Class EventServiceProvider.
|
||||
* @codeCoverageIgnore
|
||||
*/
|
||||
class EventServiceProvider extends ServiceProvider
|
||||
{
|
||||
/**
|
||||
* @codeCoverageIgnore
|
||||
* The event listener mappings for the application.
|
||||
*
|
||||
* @var array
|
||||
@@ -103,7 +103,6 @@ class EventServiceProvider extends ServiceProvider
|
||||
];
|
||||
|
||||
/**
|
||||
* @codeCoverageIgnore
|
||||
* Register any events for your application.
|
||||
*/
|
||||
public function boot(): void
|
||||
@@ -119,7 +118,7 @@ class EventServiceProvider extends ServiceProvider
|
||||
{
|
||||
// in case of repeated piggy banks and/or other problems.
|
||||
PiggyBank::created(
|
||||
function (PiggyBank $piggyBank) {
|
||||
static function (PiggyBank $piggyBank) {
|
||||
$repetition = new PiggyBankRepetition;
|
||||
$repetition->piggyBank()->associate($piggyBank);
|
||||
$repetition->startdate = $piggyBank->startdate;
|
||||
@@ -129,7 +128,7 @@ class EventServiceProvider extends ServiceProvider
|
||||
}
|
||||
);
|
||||
Client::created(
|
||||
function (Client $oauthClient) {
|
||||
static function (Client $oauthClient) {
|
||||
/** @var UserRepositoryInterface $repository */
|
||||
$repository = app(UserRepositoryInterface::class);
|
||||
$user = $repository->findNull((int)$oauthClient->user_id);
|
||||
|
||||
@@ -50,7 +50,7 @@ use FireflyIII\Repositories\User\UserRepositoryInterface;
|
||||
use FireflyIII\Services\Currency\ExchangeRateInterface;
|
||||
use FireflyIII\Services\IP\IpifyOrg;
|
||||
use FireflyIII\Services\IP\IPRetrievalInterface;
|
||||
use FireflyIII\Services\Password\PwndVerifierV2;
|
||||
use FireflyIII\Services\Password\PwndVerifierV3;
|
||||
use FireflyIII\Services\Password\Verifier;
|
||||
use FireflyIII\Support\Amount;
|
||||
use FireflyIII\Support\ExpandedForm;
|
||||
@@ -183,7 +183,7 @@ class FireflyServiceProvider extends ServiceProvider
|
||||
$this->app->bind(ExchangeRateInterface::class, $class);
|
||||
|
||||
// password verifier thing
|
||||
$this->app->bind(Verifier::class, PwndVerifierV2::class);
|
||||
$this->app->bind(Verifier::class, PwndVerifierV3::class);
|
||||
|
||||
// IP thing:
|
||||
$this->app->bind(IPRetrievalInterface::class, IpifyOrg::class);
|
||||
|
||||
Reference in New Issue
Block a user