Changeset View
Changeset View
Standalone View
Standalone View
src/tests/Feature/Jobs/PaymentMandateDisabledEmailTest.php
<?php | <?php | ||||
namespace Tests\Feature\Jobs; | namespace Tests\Feature\Jobs; | ||||
use App\Jobs\PaymentMandateDisabledEmail; | use App\Jobs\PaymentMandateDisabledEmail; | ||||
use App\Mail\PaymentMandateDisabled; | use App\Mail\PaymentMandateDisabled; | ||||
use App\User; | |||||
use Illuminate\Support\Facades\Mail; | use Illuminate\Support\Facades\Mail; | ||||
use Tests\TestCase; | use Tests\TestCase; | ||||
class PaymentMandateDisabledEmailTest extends TestCase | class PaymentMandateDisabledEmailTest extends TestCase | ||||
{ | { | ||||
/** | /** | ||||
* {@inheritDoc} | * {@inheritDoc} | ||||
* | * | ||||
Show All 20 Lines | class PaymentMandateDisabledEmailTest extends TestCase | ||||
/** | /** | ||||
* Test job handle | * Test job handle | ||||
* | * | ||||
* @return void | * @return void | ||||
*/ | */ | ||||
public function testHandle() | public function testHandle() | ||||
{ | { | ||||
$user = $this->getTestUser('PaymentEmail@UserAccount.com'); | $status = User::STATUS_ACTIVE | User::STATUS_LDAP_READY | User::STATUS_IMAP_READY; | ||||
$user = $this->getTestUser('PaymentEmail@UserAccount.com', ['status' => $status]); | |||||
$user->setSetting('external_email', 'ext@email.tld'); | $user->setSetting('external_email', 'ext@email.tld'); | ||||
$wallet = $user->wallets()->first(); | $wallet = $user->wallets()->first(); | ||||
Mail::fake(); | Mail::fake(); | ||||
// Assert that no jobs were pushed... | // Assert that no jobs were pushed... | ||||
Mail::assertNothingSent(); | Mail::assertNothingSent(); | ||||
Show All 12 Lines |