Fixes for email templates

This commit is contained in:
David Bomba 2023-08-05 10:01:44 +10:00
parent 95e4cc7afc
commit 911738c443

View File

@ -42,7 +42,7 @@ class InvoiceEmailTest extends TestCase
$this->makeTestData(); $this->makeTestData();
$this->withoutExceptionHandling(); // $this->withoutExceptionHandling();
} }
@ -58,17 +58,17 @@ class InvoiceEmailTest extends TestCase
$response = false; $response = false;
// try { try {
$response = $this->withHeaders([ $response = $this->withHeaders([
'X-API-SECRET' => config('ninja.api_secret'), 'X-API-SECRET' => config('ninja.api_secret'),
'X-API-TOKEN' => $this->token, 'X-API-TOKEN' => $this->token,
])->postJson('/api/v1/emails', $data); ])->postJson('/api/v1/emails', $data);
// } catch (ValidationException $e) { } catch (ValidationException $e) {
// $message = json_decode($e->validator->getMessageBag(), 1); $message = json_decode($e->validator->getMessageBag(), 1);
// nlog($message); nlog($message);
// } }
$response->assertStatus(200); $response->assertStatus(422);
} }