Updated tests
This commit is contained in:
parent
171d46b091
commit
d8d9976aa1
|
@ -584,15 +584,21 @@ class ProjectsConsoleClientTest extends Scope
|
|||
public function testCreateProjectSMTPTests($data): array
|
||||
{
|
||||
$id = $data['projectId'];
|
||||
$email = 'mailer@appwrite.io';
|
||||
$response = $this->client->call(Client::METHOD_PATCH, '/projects/' . $id . '/smtp/tests', array_merge([
|
||||
'content-type' => 'application/json',
|
||||
'x-appwrite-project' => $this->getProject()['$id'],
|
||||
], $this->getHeaders()), [
|
||||
'email' => 'mailer@appwrite.io',
|
||||
'email' => $email,
|
||||
]);
|
||||
|
||||
$this->assertEquals(204, $response['headers']['status-code']);
|
||||
|
||||
$lastEmail = $this->getLastEmail();
|
||||
|
||||
$this->assertEquals($email, $lastEmail['to'][0]['address']);
|
||||
$this->assertEquals('SMTP test email from Appwrite', $lastEmail['subject']);
|
||||
|
||||
return $data;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue