openvidu-test-e2e: test new RecordingProperties

pull/621/head
pabloFuente 2021-04-13 14:02:51 +02:00
parent 6eca1f1e71
commit c2c3c1d193
1 changed files with 13 additions and 1 deletions

View File

@ -1014,7 +1014,9 @@ public class OpenViduTestAppE2eTest extends AbstractOpenViduTestAppE2eTest {
log.info("Composed record"); log.info("Composed record");
final String sessionName = "COMPOSED_RECORDED_SESSION"; final String sessionName = "COMPOSED_RECORDED_SESSION";
final String resolution = "1280x720"; final String resolution = "1200x700";
final int frameRate = 16;
final long shmSize = 500000000;
user.getDriver().findElement(By.id("add-user-btn")).click(); user.getDriver().findElement(By.id("add-user-btn")).click();
user.getDriver().findElement(By.id("session-name-input-0")).clear(); user.getDriver().findElement(By.id("session-name-input-0")).clear();
@ -1074,6 +1076,12 @@ public class OpenViduTestAppE2eTest extends AbstractOpenViduTestAppE2eTest {
WebElement resolutionField = user.getDriver().findElement(By.id("recording-resolution-field")); WebElement resolutionField = user.getDriver().findElement(By.id("recording-resolution-field"));
resolutionField.clear(); resolutionField.clear();
resolutionField.sendKeys(resolution); resolutionField.sendKeys(resolution);
WebElement frameRateField = user.getDriver().findElement(By.id("recording-framerate-field"));
frameRateField.clear();
frameRateField.sendKeys(String.valueOf(frameRate));
WebElement shmSizeField = user.getDriver().findElement(By.id("recording-shmsize-field"));
shmSizeField.clear();
shmSizeField.sendKeys(String.valueOf(shmSize));
user.getDriver().findElement(By.id("start-recording-btn")).click(); user.getDriver().findElement(By.id("start-recording-btn")).click();
@ -2960,8 +2968,12 @@ public class OpenViduTestAppE2eTest extends AbstractOpenViduTestAppE2eTest {
restClient.rest(HttpMethod.POST, "/openvidu/api/recordings/start", body, HttpStatus.SC_UNPROCESSABLE_ENTITY); restClient.rest(HttpMethod.POST, "/openvidu/api/recordings/start", body, HttpStatus.SC_UNPROCESSABLE_ENTITY);
body = "{'session':'CUSTOM_SESSION_ID','name':'NAME','outputMode':'COMPOSED','recordingLayout':'BEST_FIT','customLayout':'CUSTOM_LAYOUT','hasAudio':true,'hasVideo':true,'resolution':'1920x2000'}"; body = "{'session':'CUSTOM_SESSION_ID','name':'NAME','outputMode':'COMPOSED','recordingLayout':'BEST_FIT','customLayout':'CUSTOM_LAYOUT','hasAudio':true,'hasVideo':true,'resolution':'1920x2000'}";
restClient.rest(HttpMethod.POST, "/openvidu/api/recordings/start", body, HttpStatus.SC_UNPROCESSABLE_ENTITY); restClient.rest(HttpMethod.POST, "/openvidu/api/recordings/start", body, HttpStatus.SC_UNPROCESSABLE_ENTITY);
body = "{'session':'CUSTOM_SESSION_ID','name':'NAME','outputMode':'COMPOSED','recordingLayout':'BEST_FIT','customLayout':'CUSTOM_LAYOUT','hasAudio':true,'hasVideo':true,'resolution':'99x1080'}";
restClient.rest(HttpMethod.POST, "/openvidu/api/recordings/start", body, HttpStatus.SC_UNPROCESSABLE_ENTITY);
body = "{'session':'CUSTOM_SESSION_ID','name':'NAME','outputMode':'COMPOSED','recordingLayout':'BEST_FIT','customLayout':'CUSTOM_LAYOUT','hasAudio':true,'hasVideo':true,'frameRate':0}"; body = "{'session':'CUSTOM_SESSION_ID','name':'NAME','outputMode':'COMPOSED','recordingLayout':'BEST_FIT','customLayout':'CUSTOM_LAYOUT','hasAudio':true,'hasVideo':true,'frameRate':0}";
restClient.rest(HttpMethod.POST, "/openvidu/api/recordings/start", body, HttpStatus.SC_UNPROCESSABLE_ENTITY); restClient.rest(HttpMethod.POST, "/openvidu/api/recordings/start", body, HttpStatus.SC_UNPROCESSABLE_ENTITY);
body = "{'session':'CUSTOM_SESSION_ID','name':'NAME','outputMode':'COMPOSED','recordingLayout':'BEST_FIT','customLayout':'CUSTOM_LAYOUT','hasAudio':true,'hasVideo':true,'frameRate':121}";
restClient.rest(HttpMethod.POST, "/openvidu/api/recordings/start", body, HttpStatus.SC_UNPROCESSABLE_ENTITY);
// 200 // 200
body = "{'session':'CUSTOM_SESSION_ID'}"; body = "{'session':'CUSTOM_SESSION_ID'}";