summaryrefslogtreecommitdiffstats
path: root/uitest
diff options
context:
space:
mode:
authorJohannes Dahlström <johannesd@vaadin.com>2015-01-13 12:21:53 +0200
committerTeemu Suo-Anttila <teemusa@vaadin.com>2015-01-14 10:26:35 +0000
commit714384ea8a053ab75bec050a1fc67a56aeee8bd5 (patch)
tree0f5349beb78869c85852da3cb75c0f4a212f44f1 /uitest
parent35372dc1d3ede9d2005ac8bda5d5a7e4f3aba98d (diff)
downloadvaadin-framework-714384ea8a053ab75bec050a1fc67a56aeee8bd5.tar.gz
vaadin-framework-714384ea8a053ab75bec050a1fc67a56aeee8bd5.zip
Fix IndexOutOfBoundsException in RpcDataProviderExtension (#15443)
Change-Id: I5688e369bd6247afe0c8ed381964445dfc2c1ec1
Diffstat (limited to 'uitest')
-rw-r--r--uitest/src/com/vaadin/tests/components/grid/basicfeatures/server/GridEditorTest.java6
-rw-r--r--uitest/src/com/vaadin/tests/components/grid/basicfeatures/server/GridRowAddRemoveTest.java4
-rw-r--r--uitest/src/com/vaadin/tests/components/grid/basicfeatures/server/GridStaticSectionComponentTest.java6
-rw-r--r--uitest/src/com/vaadin/tests/components/grid/basicfeatures/server/LoadingIndicatorTest.java5
4 files changed, 11 insertions, 10 deletions
diff --git a/uitest/src/com/vaadin/tests/components/grid/basicfeatures/server/GridEditorTest.java b/uitest/src/com/vaadin/tests/components/grid/basicfeatures/server/GridEditorTest.java
index 35b2fc24fe..74c3c0db35 100644
--- a/uitest/src/com/vaadin/tests/components/grid/basicfeatures/server/GridEditorTest.java
+++ b/uitest/src/com/vaadin/tests/components/grid/basicfeatures/server/GridEditorTest.java
@@ -59,8 +59,7 @@ public class GridEditorTest extends GridBasicFeaturesTest {
selectMenuPath("Component", "Editor", "Enabled");
selectMenuPath("Component", "Editor", "Edit item 5");
assertEditorClosed();
- boolean thrown = getLogRow(0).startsWith(
- "5. Exception occured, java.lang.IllegalStateException");
+ boolean thrown = logContainsText("Exception occured, java.lang.IllegalStateException");
assertTrue("IllegalStateException thrown", thrown);
}
@@ -69,8 +68,7 @@ public class GridEditorTest extends GridBasicFeaturesTest {
selectMenuPath("Component", "Editor", "Edit item 5");
selectMenuPath("Component", "Editor", "Enabled");
assertEditorOpen();
- boolean thrown = getLogRow(0).startsWith(
- "5. Exception occured, java.lang.IllegalStateException");
+ boolean thrown = logContainsText("Exception occured, java.lang.IllegalStateException");
assertTrue("IllegalStateException thrown", thrown);
}
diff --git a/uitest/src/com/vaadin/tests/components/grid/basicfeatures/server/GridRowAddRemoveTest.java b/uitest/src/com/vaadin/tests/components/grid/basicfeatures/server/GridRowAddRemoveTest.java
index 28c9e441dc..8535efb9ef 100644
--- a/uitest/src/com/vaadin/tests/components/grid/basicfeatures/server/GridRowAddRemoveTest.java
+++ b/uitest/src/com/vaadin/tests/components/grid/basicfeatures/server/GridRowAddRemoveTest.java
@@ -30,9 +30,9 @@ public class GridRowAddRemoveTest extends GridBasicFeaturesTest {
selectMenuPath("Component", "Body rows", "Remove all rows");
selectMenuPath("Component", "Body rows", "Add 18 rows");
- Assert.assertEquals(
+ Assert.assertTrue(
"All added rows should be fetched in the same round trip.",
- "2. Requested items 0 - 18", getLogRow(0));
+ logContainsText("Requested items 0 - 18"));
}
@Test
diff --git a/uitest/src/com/vaadin/tests/components/grid/basicfeatures/server/GridStaticSectionComponentTest.java b/uitest/src/com/vaadin/tests/components/grid/basicfeatures/server/GridStaticSectionComponentTest.java
index bf1d1329aa..2fbaa58cab 100644
--- a/uitest/src/com/vaadin/tests/components/grid/basicfeatures/server/GridStaticSectionComponentTest.java
+++ b/uitest/src/com/vaadin/tests/components/grid/basicfeatures/server/GridStaticSectionComponentTest.java
@@ -35,7 +35,8 @@ public class GridStaticSectionComponentTest extends GridBasicFeaturesTest {
getGridElement().$(ButtonElement.class).first().click();
- assertEquals("3. Button clicked!", getLogRow(0));
+ assertTrue("Button click should be logged",
+ logContainsText("Button clicked!"));
}
@Test
@@ -49,7 +50,8 @@ public class GridStaticSectionComponentTest extends GridBasicFeaturesTest {
getGridElement().$(ButtonElement.class).first().click();
- assertEquals("5. Button clicked!", getLogRow(0));
+ assertTrue("Button click should be logged",
+ logContainsText("Button clicked!"));
}
@Test
diff --git a/uitest/src/com/vaadin/tests/components/grid/basicfeatures/server/LoadingIndicatorTest.java b/uitest/src/com/vaadin/tests/components/grid/basicfeatures/server/LoadingIndicatorTest.java
index 1f16efdd39..b122eb02e9 100644
--- a/uitest/src/com/vaadin/tests/components/grid/basicfeatures/server/LoadingIndicatorTest.java
+++ b/uitest/src/com/vaadin/tests/components/grid/basicfeatures/server/LoadingIndicatorTest.java
@@ -68,8 +68,9 @@ public class LoadingIndicatorTest extends GridBasicFeaturesTest {
Thread.sleep(2000);
String firstLogRow = getLogRow(0);
- Assert.assertTrue("Last log message was not the fourth message: "
- + firstLogRow, firstLogRow.startsWith("4. Requested items"));
+ Assert.assertTrue(
+ "Last log message should be number 6: " + firstLogRow,
+ firstLogRow.startsWith("6. Requested items"));
}
private boolean isLoadingIndicatorVisible() {