diff options
author | Artur Signell <artur@vaadin.com> | 2015-09-04 12:53:03 +0300 |
---|---|---|
committer | Artur Signell <artur@vaadin.com> | 2015-09-04 13:01:02 +0300 |
commit | f03e488f206c92f321e7e79bfb9c86c56077b341 (patch) | |
tree | 9480f6b48e99bd3a0e4d4d97dd63b94fb90d3778 /uitest/src/com/vaadin/tests/integration | |
parent | 3b4bd95b6e9383949bf8cf61d8b0b2c08b8443aa (diff) | |
download | vaadin-framework-f03e488f206c92f321e7e79bfb9c86c56077b341.tar.gz vaadin-framework-f03e488f206c92f321e7e79bfb9c86c56077b341.zip |
Additional fixes related to ParameterizedTB3Runner and Nginx + Wildfly 9 test changes
Change-Id: Ib6740b10fe773c2d54973ea45a1aca0d29afeb49
Diffstat (limited to 'uitest/src/com/vaadin/tests/integration')
-rw-r--r-- | uitest/src/com/vaadin/tests/integration/LongPollingProxyServerTest.java | 22 | ||||
-rw-r--r-- | uitest/src/com/vaadin/tests/integration/ParameterizedTB3Runner.java | 7 |
2 files changed, 14 insertions, 15 deletions
diff --git a/uitest/src/com/vaadin/tests/integration/LongPollingProxyServerTest.java b/uitest/src/com/vaadin/tests/integration/LongPollingProxyServerTest.java index 58c4198ec0..16c599641b 100644 --- a/uitest/src/com/vaadin/tests/integration/LongPollingProxyServerTest.java +++ b/uitest/src/com/vaadin/tests/integration/LongPollingProxyServerTest.java @@ -67,20 +67,25 @@ public class LongPollingProxyServerTest extends AbstractIntegrationTest { actionAfterFirstTimeout("nonbuffering-timeout"); } + private String getUrl(String bufferingOrNot) { + return getBaseURL() + "/" + bufferingOrNot + "/demo" + + getDeploymentPath(); + } + private void actionAfterFirstTimeout(String bufferingOrNot) throws Exception { - String url = getBaseURL() + "/" + bufferingOrNot + "/demo" - + getDeploymentPath(); + String url = getUrl(bufferingOrNot); getDriver().get(url); - Thread.sleep(15000); // Server Timeout is 10s + // The wildfly9-nginx server has a configured timeout of 10s for + // *-timeout urls + Thread.sleep(15000); Assert.assertEquals(0, BasicPushTest.getClientCounter(this)); BasicPushTest.getIncrementButton(this).click(); Assert.assertEquals(1, BasicPushTest.getClientCounter(this)); } private void basicPush(String bufferingOrNot) throws Exception { - String url = getBaseURL() + "/" + bufferingOrNot + "/demo" - + getDeploymentPath(); + String url = getUrl(bufferingOrNot); getDriver().get(url); Assert.assertEquals(0, BasicPushTest.getServerCounter(this)); @@ -89,13 +94,6 @@ public class LongPollingProxyServerTest extends AbstractIntegrationTest { @Override public Boolean apply(WebDriver input) { return BasicPushTest - .getServerCounter(LongPollingProxyServerTest.this) > 0; - } - }); - waitUntil(new ExpectedCondition<Boolean>() { - @Override - public Boolean apply(WebDriver input) { - return BasicPushTest .getServerCounter(LongPollingProxyServerTest.this) > 1; } }); diff --git a/uitest/src/com/vaadin/tests/integration/ParameterizedTB3Runner.java b/uitest/src/com/vaadin/tests/integration/ParameterizedTB3Runner.java index 59870a59a8..b051fb51db 100644 --- a/uitest/src/com/vaadin/tests/integration/ParameterizedTB3Runner.java +++ b/uitest/src/com/vaadin/tests/integration/ParameterizedTB3Runner.java @@ -99,13 +99,14 @@ public class ParameterizedTB3Runner extends TB3Runner { try { values = (Collection<String>) m.invoke(null); if (!values.isEmpty()) { - // Ignore any empty collections to allow e.g. intergration + // Ignore any empty collections to allow e.g. integration // tests to use "/demo" path by default without adding that - // to the screnshot name + // to the screenshot name parameters.put(setterMethod, values); } } catch (Exception e) { - e.printStackTrace(); + throw new IllegalStateException("The setter " + m.getName() + + " could not be invoked", e); } } |