From b4ff7fec1e4fa646d7bfd809f1a7bd002a9facdc Mon Sep 17 00:00:00 2001 From: Philipp Lang Date: Mon, 7 Nov 2022 16:26:55 +0100 Subject: [PATCH] fix leterSendAction --- app/Letter/Actions/LetterSendAction.php | 2 +- tests/Feature/Letter/LetterSendActionTest.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Letter/Actions/LetterSendAction.php b/app/Letter/Actions/LetterSendAction.php index aaf641b5..14cbd70c 100644 --- a/app/Letter/Actions/LetterSendAction.php +++ b/app/Letter/Actions/LetterSendAction.php @@ -31,7 +31,7 @@ class LetterSendAction /** * Execute the console command. */ - private function handle(): int + public function handle(): int { foreach (app(DocumentFactory::class)->types as $type) { $letters = app(DocumentFactory::class)->repoCollection($type, 'E-Mail'); diff --git a/tests/Feature/Letter/LetterSendActionTest.php b/tests/Feature/Letter/LetterSendActionTest.php index 1a0f67c1..c6f7c060 100644 --- a/tests/Feature/Letter/LetterSendActionTest.php +++ b/tests/Feature/Letter/LetterSendActionTest.php @@ -37,7 +37,7 @@ class LetterSendActionTest extends TestCase { Mail::fake(); - LetterSendAction::run(); + app(LetterSendAction::class)->handle(); Mail::assertSent(PaymentMail::class, fn ($mail) => Storage::path('rechnung-fur-mom.pdf') === $mail->filename); }