Changeset View
Changeset View
Standalone View
Standalone View
src/tests/Feature/Controller/OpenViduTest.php
Show First 20 Lines • Show All 57 Lines • ▼ Show 20 Lines | public function testIndex(): void | ||||
// Jack has no room, but it will be auto-created | // Jack has no room, but it will be auto-created | ||||
$response = $this->actingAs($jack)->get("api/v4/openvidu/rooms"); | $response = $this->actingAs($jack)->get("api/v4/openvidu/rooms"); | ||||
$response->assertStatus(200); | $response->assertStatus(200); | ||||
$json = $response->json(); | $json = $response->json(); | ||||
$this->assertSame(1, $json['count']); | $this->assertSame(1, $json['count']); | ||||
$this->assertCount(1, $json['list']); | $this->assertCount(1, $json['list']); | ||||
$this->assertRegExp('/^[0-9a-z-]{11}$/', $json['list'][0]['name']); | $this->assertMatchesRegularExpression('/^[0-9a-z-]{11}$/', $json['list'][0]['name']); | ||||
} | } | ||||
/** | /** | ||||
* Test joining the room | * Test joining the room | ||||
* | * | ||||
* @group openvidu | * @group openvidu | ||||
*/ | */ | ||||
public function testJoinRoom(): void | public function testJoinRoom(): void | ||||
▲ Show 20 Lines • Show All 707 Lines • Show Last 20 Lines |