summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorJoas Schilling <coding@schilljs.com>2021-04-07 11:43:44 +0200
committerJoas Schilling <coding@schilljs.com>2022-05-11 13:43:50 +0200
commit0fc503a8ac7b658a50d5fb2349687ead33a65a0a (patch)
tree0a4e5c9f57655f6955253eb8a75d6c3df720e778 /tests
parent7f0f7c2d5a321d004dbef3b7aac90ad6e924f893 (diff)
Allow to disable calling functionality
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'tests')
-rw-r--r--tests/php/CapabilitiesTest.php9
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/php/CapabilitiesTest.php b/tests/php/CapabilitiesTest.php
index d7d635198..e64a66c9d 100644
--- a/tests/php/CapabilitiesTest.php
+++ b/tests/php/CapabilitiesTest.php
@@ -29,6 +29,7 @@ use OCA\Talk\Capabilities;
use OCA\Talk\Chat\CommentsManager;
use OCA\Talk\Config;
use OCA\Talk\Participant;
+use OCA\Talk\Room;
use OCP\Capabilities\IPublicCapability;
use OCP\IConfig;
use OCP\IUser;
@@ -130,6 +131,7 @@ class CapabilitiesTest extends TestCase {
->willReturnMap([
['spreed', 'has_reference_id', 'no', 'no'],
['spreed', 'max-gif-size', '3145728', '200000'],
+ ['spreed', 'start_calls', Room::START_CALL_EVERYONE, Room::START_CALL_EVERYONE],
]);
$this->assertInstanceOf(IPublicCapability::class, $capabilities);
@@ -140,6 +142,9 @@ class CapabilitiesTest extends TestCase {
'attachments' => [
'allowed' => false,
],
+ 'call' => [
+ 'enabled' => true,
+ ],
'chat' => [
'max-length' => 32000,
'read-privacy' => 0,
@@ -209,6 +214,7 @@ class CapabilitiesTest extends TestCase {
->willReturnMap([
['spreed', 'has_reference_id', 'no', 'yes'],
['spreed', 'max-gif-size', '3145728', '200000'],
+ ['spreed', 'start_calls', Room::START_CALL_EVERYONE, Room::START_CALL_NOONE],
]);
$this->assertInstanceOf(IPublicCapability::class, $capabilities);
@@ -225,6 +231,9 @@ class CapabilitiesTest extends TestCase {
'allowed' => true,
'folder' => '/Talk',
],
+ 'call' => [
+ 'enabled' => false,
+ ],
'chat' => [
'max-length' => 32000,
'read-privacy' => $readPrivacy,