aboutsummaryrefslogtreecommitdiffstats
path: root/server/tests
diff options
context:
space:
mode:
authorHenri Sara <hesara@vaadin.com>2012-11-14 12:52:21 +0200
committerHenri Sara <hesara@vaadin.com>2012-11-14 12:52:21 +0200
commit8a69b220bb80fc726e6d62ce540ee5e9402b7a63 (patch)
tree3d824b644b098066631cce41f1b5a02b258da60e /server/tests
parent1b7a4a1ee9e03f445cbfcbb520a5ac970ccf47de (diff)
downloadvaadin-framework-8a69b220bb80fc726e6d62ce540ee5e9402b7a63.tar.gz
vaadin-framework-8a69b220bb80fc726e6d62ce540ee5e9402b7a63.zip
Fix LegacyUIAddRemoveComponents test (#2924)
Change-Id: Ib6f59d3707713a5ec3c23ee552e19d87d4713862
Diffstat (limited to 'server/tests')
-rw-r--r--server/tests/src/com/vaadin/tests/server/component/ui/LegacyUIAddRemoveComponents.java8
1 files changed, 4 insertions, 4 deletions
diff --git a/server/tests/src/com/vaadin/tests/server/component/ui/LegacyUIAddRemoveComponents.java b/server/tests/src/com/vaadin/tests/server/component/ui/LegacyUIAddRemoveComponents.java
index 1a5e19e0da..24fd3d85a8 100644
--- a/server/tests/src/com/vaadin/tests/server/component/ui/LegacyUIAddRemoveComponents.java
+++ b/server/tests/src/com/vaadin/tests/server/component/ui/LegacyUIAddRemoveComponents.java
@@ -26,7 +26,7 @@ public class LegacyUIAddRemoveComponents {
ui.addComponent(c);
- assertSame(c, ui.iterator().next());
+ assertSame(c.getParent(), ui.iterator().next());
assertSame(c, ui.getContent().iterator().next());
assertEquals(1, ui.getComponentCount());
assertEquals(1, ui.getContent().getComponentCount());
@@ -41,9 +41,9 @@ public class LegacyUIAddRemoveComponents {
ui.removeComponent(c);
- assertFalse(ui.iterator().hasNext());
+ assertEquals(ui.getContent(), ui.iterator().next());
assertFalse(ui.getContent().iterator().hasNext());
- assertEquals(0, ui.getComponentCount());
+ assertEquals(1, ui.getComponentCount());
assertEquals(0, ui.getContent().getComponentCount());
}
@@ -57,7 +57,7 @@ public class LegacyUIAddRemoveComponents {
ui.replaceComponent(c, d);
- assertSame(d, ui.iterator().next());
+ assertSame(d.getParent(), ui.iterator().next());
assertSame(d, ui.getContent().iterator().next());
assertEquals(1, ui.getComponentCount());
assertEquals(1, ui.getContent().getComponentCount());