mirror of
https://github.com/appwrite/appwrite.git
synced 2026-05-26 13:51:13 +00:00
Add debug
This commit is contained in:
@@ -49,6 +49,10 @@ trait ProjectCustom
|
||||
'url' => 'https://appwrite.io',
|
||||
]);
|
||||
|
||||
if($project['headers']['status-code'] != 201){
|
||||
var_dump($project);
|
||||
}
|
||||
|
||||
$this->assertEquals(201, $project['headers']['status-code']);
|
||||
$this->assertNotEmpty($project['body']);
|
||||
|
||||
|
||||
@@ -22,19 +22,29 @@ class DatabasesPermissionsGuestTest extends Scope
|
||||
|
||||
public function createCollection(): array
|
||||
{
|
||||
$this->assertEventually(function () use (&$database) {
|
||||
$database = $this->client->call(Client::METHOD_POST, '/databases', array_merge([
|
||||
'content-type' => 'application/json',
|
||||
'x-appwrite-project' => $this->getProject()['$id'],
|
||||
'x-appwrite-key' => $this->getProject()['apiKey']
|
||||
]), [
|
||||
'databaseId' => ID::unique(),
|
||||
'name' => 'InvalidDocumentDatabase',
|
||||
]);
|
||||
// $this->assertEventually(function () use (&$database) {
|
||||
// $database = $this->client->call(Client::METHOD_POST, '/databases', array_merge([
|
||||
// 'content-type' => 'application/json',
|
||||
// 'x-appwrite-project' => $this->getProject()['$id'],
|
||||
// 'x-appwrite-key' => $this->getProject()['apiKey']
|
||||
// ]), [
|
||||
// 'databaseId' => ID::unique(),
|
||||
// 'name' => 'InvalidDocumentDatabase',
|
||||
// ]);
|
||||
//
|
||||
// $this->assertEquals(201, $database['headers']['status-code']);
|
||||
// }, 50000, 500);
|
||||
|
||||
$this->assertEquals(201, $database['headers']['status-code']);
|
||||
}, 50000, 500);
|
||||
$database = $this->client->call(Client::METHOD_POST, '/databases', array_merge([
|
||||
'content-type' => 'application/json',
|
||||
'x-appwrite-project' => $this->getProject()['$id'],
|
||||
'x-appwrite-key' => $this->getProject()['apiKey']
|
||||
]), [
|
||||
'databaseId' => ID::unique(),
|
||||
'name' => 'InvalidDocumentDatabase',
|
||||
]);
|
||||
|
||||
$this->assertEquals(201, $database['headers']['status-code']);
|
||||
$this->assertEquals('InvalidDocumentDatabase', $database['body']['name']);
|
||||
|
||||
$databaseId = $database['body']['$id'];
|
||||
|
||||
Reference in New Issue
Block a user