Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/spreed.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorSebastian L <sl@momou.ch>2021-05-05 10:01:29 +0300
committerSebastian L <sl@momou.ch>2021-05-07 12:54:28 +0300
commit37fba2795ba5be7b3306f9abdd671d2821fccad1 (patch)
tree2884c8220a78169a5f7e133066faacdab5969ad5 /tests
parentf549e525bcce69fafbf12c6e938bdf8ea49d2d8a (diff)
Provide multiple STUN servers to webrtc client
- Provide multiple STUN servers to webrtc client when specified in nextcloud backend instead of just 1 random one Signed-off-by: Sebastian L <sl@momou.ch>
Diffstat (limited to 'tests')
-rw-r--r--tests/php/ConfigTest.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/php/ConfigTest.php b/tests/php/ConfigTest.php
index c533e36f2..0cb2d9d95 100644
--- a/tests/php/ConfigTest.php
+++ b/tests/php/ConfigTest.php
@@ -29,7 +29,7 @@ use PHPUnit\Framework\MockObject\MockObject;
use Test\TestCase;
class ConfigTest extends TestCase {
- public function testGetStunServer() {
+ public function testGetStunServers() {
$servers = [
'stun1.example.com:443',
'stun2.example.com:129',
@@ -55,7 +55,7 @@ class ConfigTest extends TestCase {
->willReturn(true);
$helper = new Config($config, $secureRandom, $groupManager, $timeFactory);
- $this->assertTrue(in_array($helper->getStunServer(), $servers, true));
+ $this->assertSame($helper->getStunServers(), $servers);
}
public function testGetDefaultStunServer() {
@@ -79,7 +79,7 @@ class ConfigTest extends TestCase {
->willReturn(true);
$helper = new Config($config, $secureRandom, $groupManager, $timeFactory);
- $this->assertSame('stun.nextcloud.com:443', $helper->getStunServer());
+ $this->assertSame(['stun.nextcloud.com:443'], $helper->getStunServers());
}
public function testGetDefaultStunServerNoInternet() {
@@ -103,7 +103,7 @@ class ConfigTest extends TestCase {
->willReturn(false);
$helper = new Config($config, $secureRandom, $groupManager, $timeFactory);
- $this->assertSame('', $helper->getStunServer());
+ $this->assertSame([], $helper->getStunServers());
}
public function testGenerateTurnSettings() {