openvidu-test-e2e: active wait time in publish-unpublish test

pull/73/head
pabloFuente 2018-05-17 20:41:24 +02:00
parent b5698a75dc
commit 65fb9505e9
1 changed files with 3 additions and 1 deletions

View File

@ -637,6 +637,7 @@ public class OpenViduTestAppE2eTest {
for (WebElement el : publishButtons) { for (WebElement el : publishButtons) {
el.click(); el.click();
Thread.sleep(1000);
} }
user.getEventManager().waitUntilEventReaches("videoPlaying", 8); user.getEventManager().waitUntilEventReaches("videoPlaying", 8);
@ -765,7 +766,8 @@ public class OpenViduTestAppE2eTest {
return new ExpectedCondition<Boolean>() { return new ExpectedCondition<Boolean>() {
@Override @Override
public Boolean apply(WebDriver input) { public Boolean apply(WebDriver input) {
return element.getAttribute("duration").matches(durationInSeconds - 1 + "\\.9[0-9]{0,5}|" + durationInSeconds + "\\.[0-1][0-9]{0,5}"); return element.getAttribute("duration")
.matches(durationInSeconds - 1 + "\\.9[0-9]{0,5}|" + durationInSeconds + "\\.[0-1][0-9]{0,5}");
} }
}; };
} }