summaryrefslogtreecommitdiffstats
path: root/uitest/src/com/vaadin/tests/application
diff options
context:
space:
mode:
authorLeif Åstrand <leif@vaadin.com>2013-09-23 16:06:17 +0300
committerVaadin Code Review <review@vaadin.com>2013-09-25 06:49:35 +0000
commit3940d851365ce4d18c599893aed7dfa4b5e0f46f (patch)
treef82a01c616e3d6b944e26dbf36169d77223b1f6b /uitest/src/com/vaadin/tests/application
parente577bf9f0c99f340ef5d05e60f01f1378b68d097 (diff)
downloadvaadin-framework-3940d851365ce4d18c599893aed7dfa4b5e0f46f.tar.gz
vaadin-framework-3940d851365ce4d18c599893aed7dfa4b5e0f46f.zip
Use explicit button for reading asynchronously created messages (#10338)
Change-Id: Icde7e1f612ed60867b3d3d58aedbe36d16ad61a5
Diffstat (limited to 'uitest/src/com/vaadin/tests/application')
-rw-r--r--uitest/src/com/vaadin/tests/application/DetachOldUIOnReload.html15
-rw-r--r--uitest/src/com/vaadin/tests/application/DetachOldUIOnReload.java13
2 files changed, 24 insertions, 4 deletions
diff --git a/uitest/src/com/vaadin/tests/application/DetachOldUIOnReload.html b/uitest/src/com/vaadin/tests/application/DetachOldUIOnReload.html
index 038283324d..33fc46f060 100644
--- a/uitest/src/com/vaadin/tests/application/DetachOldUIOnReload.html
+++ b/uitest/src/com/vaadin/tests/application/DetachOldUIOnReload.html
@@ -27,6 +27,11 @@
<td></td>
</tr>
<tr>
+ <td>click</td>
+ <td>vaadin=runcomvaadintestsapplicationDetachOldUIOnReload::/VVerticalLayout[0]/Slot[2]/VVerticalLayout[0]/Slot[2]/VButton[0]/domChild[0]/domChild[0]</td>
+ <td></td>
+</tr>
+<tr>
<td>assertText</td>
<td>vaadin=runcomvaadintestsapplicationDetachOldUIOnReload::PID_SLog_row_0</td>
<td>1. UI 0 has been detached</td>
@@ -42,6 +47,11 @@
<td></td>
</tr>
<tr>
+ <td>click</td>
+ <td>vaadin=runcomvaadintestsapplicationDetachOldUIOnReload::/VVerticalLayout[0]/Slot[2]/VVerticalLayout[0]/Slot[2]/VButton[0]/domChild[0]/domChild[0]</td>
+ <td></td>
+</tr>
+<tr>
<td>assertText</td>
<td>vaadin=runcomvaadintestsapplicationDetachOldUIOnReload::PID_SLog_row_0</td>
<td>2. UI 1 has been detached</td>
@@ -62,6 +72,11 @@
<td></td>
</tr>
<tr>
+ <td>click</td>
+ <td>vaadin=runcomvaadintestsapplicationDetachOldUIOnReload::/VVerticalLayout[0]/Slot[2]/VVerticalLayout[0]/Slot[2]/VButton[0]/domChild[0]/domChild[0]</td>
+ <td></td>
+</tr>
+<tr>
<td>assertText</td>
<td>vaadin=runcomvaadintestsapplicationDetachOldUIOnReload::PID_SLog_row_0</td>
<td>3. UI 2 has been detached</td>
diff --git a/uitest/src/com/vaadin/tests/application/DetachOldUIOnReload.java b/uitest/src/com/vaadin/tests/application/DetachOldUIOnReload.java
index 7104146203..154c84b4f5 100644
--- a/uitest/src/com/vaadin/tests/application/DetachOldUIOnReload.java
+++ b/uitest/src/com/vaadin/tests/application/DetachOldUIOnReload.java
@@ -31,10 +31,6 @@ public class DetachOldUIOnReload extends AbstractTestUIWithLog {
@Override
protected void setup(VaadinRequest request) {
- for (String message : getSessionMessages(false)) {
- log(message);
- }
-
addComponent(new Label("This is UI " + getUIId()));
addComponent(new Button("Reload page", new Button.ClickListener() {
@Override
@@ -42,6 +38,15 @@ public class DetachOldUIOnReload extends AbstractTestUIWithLog {
getPage().reload();
}
}));
+ addComponent(new Button("Read log messages from session",
+ new Button.ClickListener() {
+ @Override
+ public void buttonClick(ClickEvent event) {
+ for (String message : getSessionMessages(false)) {
+ log(message);
+ }
+ }
+ }));
}
private List<String> getSessionMessages(boolean storeIfNeeded) {