mirror of https://github.com/OpenVidu/openvidu.git
openvidu-test-e2e: improved quick start record test
parent
b9d28d11cd
commit
eb7fb81995
|
@ -1246,6 +1246,17 @@ public class OpenViduTestAppE2eTest {
|
||||||
|
|
||||||
log.info("Remote composed quick start record");
|
log.info("Remote composed quick start record");
|
||||||
|
|
||||||
|
CountDownLatch initLatch = new CountDownLatch(1);
|
||||||
|
io.openvidu.test.browsers.utils.CustomWebhook.main(new String[0], initLatch);
|
||||||
|
|
||||||
|
try {
|
||||||
|
|
||||||
|
if (!initLatch.await(30, TimeUnit.SECONDS)) {
|
||||||
|
Assert.fail("Timeout waiting for webhook springboot app to start");
|
||||||
|
CustomWebhook.shutDown();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
final String sessionName = "COMPOSED_QUICK_START_RECORDED_SESSION";
|
final String sessionName = "COMPOSED_QUICK_START_RECORDED_SESSION";
|
||||||
|
|
||||||
// 1. MANUAL mode and recording explicitly stopped
|
// 1. MANUAL mode and recording explicitly stopped
|
||||||
|
@ -1287,9 +1298,10 @@ public class OpenViduTestAppE2eTest {
|
||||||
OV.fetch();
|
OV.fetch();
|
||||||
String recId = OV.startRecording(sessionName).getId();
|
String recId = OV.startRecording(sessionName).getId();
|
||||||
user.getEventManager().waitUntilEventReaches("recordingStarted", 2);
|
user.getEventManager().waitUntilEventReaches("recordingStarted", 2);
|
||||||
|
CustomWebhook.waitForEvent("recordingStatusChanged", 1);
|
||||||
checkDockerContainerRunning("openvidu/openvidu-recording", 1);
|
checkDockerContainerRunning("openvidu/openvidu-recording", 1);
|
||||||
|
|
||||||
Thread.sleep(1000);
|
Thread.sleep(2000);
|
||||||
|
|
||||||
Assert.assertEquals("Wrong number of recordings found", 1, OV.listRecordings().size());
|
Assert.assertEquals("Wrong number of recordings found", 1, OV.listRecordings().size());
|
||||||
OV.stopRecording(recId);
|
OV.stopRecording(recId);
|
||||||
|
@ -1327,7 +1339,7 @@ public class OpenViduTestAppE2eTest {
|
||||||
user.getEventManager().waitUntilEventReaches("streamCreated", 3);
|
user.getEventManager().waitUntilEventReaches("streamCreated", 3);
|
||||||
user.getEventManager().waitUntilEventReaches("streamPlaying", 3);
|
user.getEventManager().waitUntilEventReaches("streamPlaying", 3);
|
||||||
user.getEventManager().waitUntilEventReaches("recordingStarted", 3);
|
user.getEventManager().waitUntilEventReaches("recordingStarted", 3);
|
||||||
|
CustomWebhook.waitForEvent("recordingStatusChanged", 1);
|
||||||
checkDockerContainerRunning("openvidu/openvidu-recording", 1);
|
checkDockerContainerRunning("openvidu/openvidu-recording", 1);
|
||||||
|
|
||||||
OV.fetch();
|
OV.fetch();
|
||||||
|
@ -1335,6 +1347,9 @@ public class OpenViduTestAppE2eTest {
|
||||||
session.close();
|
session.close();
|
||||||
|
|
||||||
checkDockerContainerRunning("openvidu/openvidu-recording", 0);
|
checkDockerContainerRunning("openvidu/openvidu-recording", 0);
|
||||||
|
} finally {
|
||||||
|
CustomWebhook.shutDown();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
|
Loading…
Reference in New Issue