1
0
Fork 0
mirror of synced 2024-10-02 10:16:27 +13:00

Apply suggestions from code review

This commit is contained in:
Christy Jacob 2023-04-30 01:54:45 +05:30 committed by GitHub
parent 3f61db57b9
commit 33d2e94d1d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 4 additions and 4 deletions

View file

@ -492,7 +492,7 @@ return [
Exception::PROJECT_ALREADY_EXISTS => [
'name' => Exception::PROJECT_ALREADY_EXISTS,
'description' => 'Project with the requested ID already exists.',
'code' => 403,
'code' => 409,
],
Exception::PROJECT_UNKNOWN => [
'name' => Exception::PROJECT_UNKNOWN,

View file

@ -6,7 +6,7 @@
convertNoticesToExceptions="true"
convertWarningsToExceptions="true"
processIsolation="false"
stopOnFailure="true"
stopOnFailure="false"
>
<extensions>
<extension class="Appwrite\Tests\TestHook" />

View file

@ -126,8 +126,8 @@ class ProjectsConsoleClientTest extends Scope
'region' => 'default'
]);
$this->assertEquals(403, $response['headers']['status-code']);
$this->assertEquals(403, $response['body']['code']);
$this->assertEquals(409, $response['headers']['status-code']);
$this->assertEquals(409, $response['body']['code']);
$this->assertEquals(Exception::PROJECT_ALREADY_EXISTS, $response['body']['type']);
$this->assertEquals('Project with the requested ID already exists.', $response['body']['message']);
}