]> source.dussan.org Git - vaadin-framework.git/commitdiff
Use explicit button for reading asynchronously created messages (#10338)
authorLeif Åstrand <leif@vaadin.com>
Mon, 23 Sep 2013 13:06:17 +0000 (16:06 +0300)
committerVaadin Code Review <review@vaadin.com>
Wed, 25 Sep 2013 06:49:35 +0000 (06:49 +0000)
Change-Id: Icde7e1f612ed60867b3d3d58aedbe36d16ad61a5

uitest/src/com/vaadin/tests/application/DetachOldUIOnReload.html
uitest/src/com/vaadin/tests/application/DetachOldUIOnReload.java

index 038283324dc1b63ff80b435d6703a4fc97fc51e0..33fc46f0601a1a7eb9be389a99c20f95b61b53b2 100644 (file)
        <td>/run/com.vaadin.tests.application.DetachOldUIOnReload</td>
        <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>vaadin=runcomvaadintestsapplicationDetachOldUIOnReload::/VVerticalLayout[0]/Slot[2]/VVerticalLayout[0]/Slot[1]/VButton[0]/domChild[0]/domChild[0]</td>
        <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>/run/com.vaadin.tests.application.DetachOldUIOnReload</td>
        <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>
index 71041462034dd3b054b83289590fdd72f7d418cb..154c84b4f5e0e6db8d8a4e9d249bb88fdb8c3fea 100644 (file)
@@ -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) {