mirror of
https://github.com/appwrite/appwrite.git
synced 2026-05-26 13:51:13 +00:00
Fix tests
This commit is contained in:
@@ -555,7 +555,7 @@ App::init()
|
||||
*/
|
||||
|
||||
App::init()
|
||||
->groups(['database', 'functions', 'messaging'])
|
||||
->groups(['database', 'functions', 'sites', 'messaging'])
|
||||
->inject('project')
|
||||
->inject('request')
|
||||
->action(function (Document $project, Request $request) {
|
||||
|
||||
@@ -30,7 +30,6 @@ class Get extends Base
|
||||
->setHttpPath('/v1/functions/templates/:templateId')
|
||||
->desc('Get function template')
|
||||
->label('scope', 'public')
|
||||
->groups(['api', 'functions'])
|
||||
->label('resourceType', RESOURCE_TYPE_FUNCTIONS)
|
||||
->label('sdk', new Method(
|
||||
namespace: 'functions',
|
||||
|
||||
@@ -29,9 +29,8 @@ class XList extends Base
|
||||
$this
|
||||
->setHttpMethod(Action::HTTP_REQUEST_METHOD_GET)
|
||||
->setHttpPath('/v1/functions/templates')
|
||||
->desc('List function templates')
|
||||
->desc('List templates')
|
||||
->label('scope', 'public')
|
||||
->groups(['api', 'functions'])
|
||||
->label('resourceType', RESOURCE_TYPE_FUNCTIONS)
|
||||
->label('sdk', new Method(
|
||||
namespace: 'functions',
|
||||
|
||||
@@ -30,7 +30,6 @@ class Get extends Base
|
||||
->setHttpPath('/v1/sites/templates/:templateId')
|
||||
->desc('Get site template')
|
||||
->label('scope', 'public')
|
||||
->groups(['api', 'sites'])
|
||||
->label('sdk', new Method(
|
||||
namespace: 'sites',
|
||||
name: 'getTemplate',
|
||||
|
||||
@@ -31,7 +31,6 @@ class XList extends Base
|
||||
->setHttpPath('/v1/sites/templates')
|
||||
->desc('List templates')
|
||||
->label('scope', 'public')
|
||||
->groups(['api', 'sites'])
|
||||
->label('sdk', new Method(
|
||||
namespace: 'sites',
|
||||
name: 'listTemplates',
|
||||
|
||||
@@ -276,7 +276,7 @@ class FunctionsCustomClientTest extends Scope
|
||||
*/
|
||||
// List all templates
|
||||
$templates = $this->client->call(Client::METHOD_GET, '/functions/templates', array_merge([
|
||||
'content-type' => 'application/json',
|
||||
'content-type' => 'application/json'
|
||||
], $this->getHeaders()));
|
||||
|
||||
$this->assertEquals(200, $templates['headers']['status-code']);
|
||||
|
||||
Reference in New Issue
Block a user