feature: send thankscard page
This commit is contained in:
@@ -27,7 +27,7 @@ class SendThankCardTest extends TestCase
|
||||
'name' => 'Sender User',
|
||||
'mail' => 'sender@example.com',
|
||||
'pass' => md5('password'),
|
||||
'departments' => 1,
|
||||
'departments' => config('constants.DEPARTMENTS')[0],
|
||||
'role' => config('constants.ROLE_MEMBER'),
|
||||
'status' => config('constants.STATUS_ACTIVE'),
|
||||
'card' => 10,
|
||||
@@ -40,7 +40,7 @@ class SendThankCardTest extends TestCase
|
||||
'name' => 'Receiver User',
|
||||
'mail' => 'receiver@example.com',
|
||||
'pass' => md5('password'),
|
||||
'departments' => 1,
|
||||
'departments' => config('constants.DEPARTMENTS')[0],
|
||||
'role' => config('constants.ROLE_MEMBER'),
|
||||
'status' => config('constants.STATUS_ACTIVE'),
|
||||
'card' => 0,
|
||||
@@ -84,7 +84,10 @@ class SendThankCardTest extends TestCase
|
||||
]);
|
||||
|
||||
$response->assertStatus(200);
|
||||
$response->assertJson(['success' => true]);
|
||||
$response->assertJson([
|
||||
'success' => true,
|
||||
'receiver_email' => 'receiver@example.com',
|
||||
]);
|
||||
|
||||
$this->sender->refresh();
|
||||
$this->assertEquals(8, $this->sender->card);
|
||||
|
||||
Reference in New Issue
Block a user