aboutsummaryrefslogtreecommitdiffstats
path: root/testbench-api/src/main/java/com/vaadin/testbench
diff options
context:
space:
mode:
authorHenri Sara <henri.sara@gmail.com>2017-02-03 13:15:13 +0200
committerGitHub <noreply@github.com>2017-02-03 13:15:13 +0200
commit167e733f1f998976569b448a1b6f52854d5e8d1e (patch)
treeec95228bcf7a5fba9f16479e3aae2c3cea4b4660 /testbench-api/src/main/java/com/vaadin/testbench
parent641351ed72a4469f9bd092b178b9e45468e7ab6b (diff)
downloadvaadin-framework-167e733f1f998976569b448a1b6f52854d5e8d1e.tar.gz
vaadin-framework-167e733f1f998976569b448a1b6f52854d5e8d1e.zip
Fix some broken tests and ComboBoxElement (#8430)
Diffstat (limited to 'testbench-api/src/main/java/com/vaadin/testbench')
-rw-r--r--testbench-api/src/main/java/com/vaadin/testbench/elements/ComboBoxElement.java10
1 files changed, 7 insertions, 3 deletions
diff --git a/testbench-api/src/main/java/com/vaadin/testbench/elements/ComboBoxElement.java b/testbench-api/src/main/java/com/vaadin/testbench/elements/ComboBoxElement.java
index dd538cecc1..dc6a59d360 100644
--- a/testbench-api/src/main/java/com/vaadin/testbench/elements/ComboBoxElement.java
+++ b/testbench-api/src/main/java/com/vaadin/testbench/elements/ComboBoxElement.java
@@ -21,7 +21,7 @@ import java.util.List;
import org.openqa.selenium.JavascriptExecutor;
import org.openqa.selenium.Keys;
-import org.openqa.selenium.NoSuchElementException;
+import org.openqa.selenium.WebDriverException;
import org.openqa.selenium.WebElement;
import com.vaadin.testbench.By;
@@ -183,7 +183,9 @@ public class ComboBoxElement extends AbstractSelectElement {
try {
getSuggestionPopup().findElement(byNextPage).click();
return true;
- } catch (NoSuchElementException e) {
+ } catch (WebDriverException e) {
+ // PhantomJS driver can throw WDE instead of the more specific
+ // NoSuchElementException
return false;
}
}
@@ -197,7 +199,9 @@ public class ComboBoxElement extends AbstractSelectElement {
try {
getSuggestionPopup().findElement(byPrevPage).click();
return true;
- } catch (NoSuchElementException e) {
+ } catch (WebDriverException e) {
+ // PhantomJS driver can throw WDE instead of the more specific
+ // NoSuchElementException
return false;
}
}