1
0
Fork 0
mirror of synced 2024-10-01 09:47:43 +13:00

Assert that webhook is disabled

This commit is contained in:
Khushboo Verma 2024-01-18 17:58:18 +05:30
parent e9aab8d9ee
commit e3f83b1335

View file

@ -1110,7 +1110,17 @@ trait WebhooksBase
$webhook = $this->getLastRequest();
$this->assertEquals($webhook['data']['name'], 'Collection1');
sleep(5);
sleep(10);
// verify that enabled is now false
$webhook = $this->client->call(Client::METHOD_GET, '/projects/' . $projectId . '/webhooks/' . $webhookId, array_merge([
'origin' => 'http://localhost',
'content-type' => 'application/json',
'cookie' => 'a_session_console=' . $this->getRoot()['session'],
'x-appwrite-project' => 'console',
]));
$this->assertEquals($webhook['body']['enabled'], false);
/**
* Test for FAILURE