From ba83dd925261ccf6acc0ef6b42fc7022bc6b85d2 Mon Sep 17 00:00:00 2001 From: Damodar Lohani Date: Sun, 15 Dec 2024 09:33:17 +0000 Subject: [PATCH] fix dev key creation --- tests/e2e/Scopes/ProjectCustom.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/e2e/Scopes/ProjectCustom.php b/tests/e2e/Scopes/ProjectCustom.php index b9561765fe..9c8041027f 100644 --- a/tests/e2e/Scopes/ProjectCustom.php +++ b/tests/e2e/Scopes/ProjectCustom.php @@ -105,8 +105,10 @@ trait ProjectCustom $this->assertNotEmpty($key['body']['secret']); $devKey = $this->client->call(Client::METHOD_POST, '/projects/' . $project['body']['$id'] . '/dev-keys', array_merge([ + 'origin' => 'http://localhost', 'content-type' => 'application/json', - 'x-appwrite-project' => $this->getProject()['$id'], + 'cookie' => 'a_session_console=' . $this->getRoot()['session'], + 'x-appwrite-project' => 'console', ], $this->getHeaders()), [ 'name' => 'Key Test', 'expire' => DateTime::addSeconds(new \DateTime(), 3600),