From 2ef2dbbe628c88669a1e6400477ef50b4c102306 Mon Sep 17 00:00:00 2001 From: iglocska Date: Sun, 20 Feb 2022 14:48:29 +0100 Subject: [PATCH] fix: [tests] changed assertion for authkey failure on insufficient privilege from 404 to 405 --- tests/TestCase/Api/AuthKeys/AddAuthKeyApiTest.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/tests/TestCase/Api/AuthKeys/AddAuthKeyApiTest.php b/tests/TestCase/Api/AuthKeys/AddAuthKeyApiTest.php index 2ede468..afb836f 100644 --- a/tests/TestCase/Api/AuthKeys/AddAuthKeyApiTest.php +++ b/tests/TestCase/Api/AuthKeys/AddAuthKeyApiTest.php @@ -65,8 +65,7 @@ class AddAuthKeyApiTest extends TestCase ] ); - $this->assertResponseCode(404); - $this->addWarning('Should return 405 Method Not Allowed instead of 404 Not Found'); + $this->assertResponseCode(405); $this->assertDbRecordNotExists('AuthKeys', ['uuid' => $uuid]); } }