summaryrefslogtreecommitdiffstats
path: root/server/tests
diff options
context:
space:
mode:
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());