Repository: zeppelin
Updated Branches:
refs/heads/master 7e045728e -> 7ccfdf705
[ZEPPELIN-2026] Flaky Test: WebDriverManager.getWebDriver() fails with Unable
to locate element 'WebSocket Connected'
### What is this PR for?
Selenium test sometimes fails with
```
Caused by: org.openqa.selenium.NoSuchElementException: Unable to locate
element: {"method":"xpath","selector":"//i[tooltip='WebSocket Connected']"}
```
This PR gives enough timeout (30s) for waiting 'WebSocket Connected' element.
Tested in my travis account 5 times and they're all green.
https://travis-ci.org/Leemoonsoo/zeppelin/builds/196428795
https://travis-ci.org/Leemoonsoo/zeppelin/builds/196429337
https://travis-ci.org/Leemoonsoo/zeppelin/builds/196429559
https://travis-ci.org/Leemoonsoo/zeppelin/builds/196429593
https://travis-ci.org/Leemoonsoo/zeppelin/builds/196430020
However, I'm not 100% sure if it really fixes the flaky test.
So, I'd like to merge this PR but keep ZEPPELIN-2026 open for next 1 week.
And then see if no selenium test fails with the error for next 1 week to close
ZEPPELIN-2026.
### What type of PR is it?
Improvement
### Todos
* [x] - Increase timeout of detecting 'connected'
### What is the Jira issue?
https://issues.apache.org/jira/browse/ZEPPELIN-2026
### How should this be tested?
CI green on Selenium test profile
### Questions:
* Does the licenses files need update? no
* Is there breaking changes for older versions? no
* Does this needs documentation? no
Author: Lee moon soo <[email protected]>
Closes #1959 from Leemoonsoo/ZEPPELIN-2026 and squashes the following commits:
87432d5 [Lee moon soo] increase timeout
Project: http://git-wip-us.apache.org/repos/asf/zeppelin/repo
Commit: http://git-wip-us.apache.org/repos/asf/zeppelin/commit/7ccfdf70
Tree: http://git-wip-us.apache.org/repos/asf/zeppelin/tree/7ccfdf70
Diff: http://git-wip-us.apache.org/repos/asf/zeppelin/diff/7ccfdf70
Branch: refs/heads/master
Commit: 7ccfdf705d3fd79590ec5d9fb7ba0b48e285ed84
Parents: 7e04572
Author: Lee moon soo <[email protected]>
Authored: Mon Jan 30 06:56:28 2017 +0900
Committer: Lee moon soo <[email protected]>
Committed: Wed Feb 1 00:46:43 2017 +0900
----------------------------------------------------------------------
.../src/test/java/org/apache/zeppelin/WebDriverManager.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/zeppelin/blob/7ccfdf70/zeppelin-server/src/test/java/org/apache/zeppelin/WebDriverManager.java
----------------------------------------------------------------------
diff --git
a/zeppelin-server/src/test/java/org/apache/zeppelin/WebDriverManager.java
b/zeppelin-server/src/test/java/org/apache/zeppelin/WebDriverManager.java
index 41bd1b0..e8cc4cc 100644
--- a/zeppelin-server/src/test/java/org/apache/zeppelin/WebDriverManager.java
+++ b/zeppelin-server/src/test/java/org/apache/zeppelin/WebDriverManager.java
@@ -122,7 +122,7 @@ public class WebDriverManager {
while (System.currentTimeMillis() - start < 60 * 1000) {
// wait for page load
try {
- (new WebDriverWait(driver, 5)).until(new ExpectedCondition<Boolean>() {
+ (new WebDriverWait(driver, 30)).until(new ExpectedCondition<Boolean>()
{
@Override
public Boolean apply(WebDriver d) {
return d.findElement(By.xpath("//i[@tooltip='WebSocket
Connected']"))