diff --git a/app/controllers/mock.php b/app/controllers/mock.php index afbb176b7e..7b33514fff 100644 --- a/app/controllers/mock.php +++ b/app/controllers/mock.php @@ -150,7 +150,11 @@ App::patch('/v1/mock/functions-v2') throw new Exception(Exception::FUNCTION_NOT_FOUND); } - $dbForProject->updateDocument('functions', $function->getId(), $function->setAttribute('version', 'v2')); + $function = $function + ->setAttribute('version', 'v2') + ->setAttribute('runtime', 'php-8.0'); + + $dbForProject->updateDocument('functions', $function->getId(), $function); $response->noContent(); }); diff --git a/tests/e2e/Services/Functions/FunctionsCustomServerTest.php b/tests/e2e/Services/Functions/FunctionsCustomServerTest.php index 0cd00d700e..ba9713021d 100644 --- a/tests/e2e/Services/Functions/FunctionsCustomServerTest.php +++ b/tests/e2e/Services/Functions/FunctionsCustomServerTest.php @@ -1422,7 +1422,7 @@ class FunctionsCustomServerTest extends Scope $functionId = $this->setupFunction([ 'functionId' => ID::unique(), 'name' => 'Test PHP V2', - 'runtime' => 'php-8.3', + 'runtime' => 'php-8.3', // Changed to php 8.0 in v2 update endpoint 'entrypoint' => 'index.php', 'events' => [], 'timeout' => 15,