From c9fe8c40d3900b7fdf72d239ad02e8e81f0fa091 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Leif=20=C3=85strand?= Date: Thu, 23 Apr 2015 15:57:05 +0300 Subject: [PATCH] Don't leak current VaadinSession in test Change-Id: I51d70636138ccf21ec4d7488aca2f071f940a51a --- .../RemoveFromParentLockingTest.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/server/tests/src/com/vaadin/tests/server/component/abstractsinglecomponentcontainer/RemoveFromParentLockingTest.java b/server/tests/src/com/vaadin/tests/server/component/abstractsinglecomponentcontainer/RemoveFromParentLockingTest.java index e277d4e075..2334542676 100644 --- a/server/tests/src/com/vaadin/tests/server/component/abstractsinglecomponentcontainer/RemoveFromParentLockingTest.java +++ b/server/tests/src/com/vaadin/tests/server/component/abstractsinglecomponentcontainer/RemoveFromParentLockingTest.java @@ -102,6 +102,8 @@ public class RemoveFromParentLockingTest { "Cannot remove from parent when the session is not locked." + " Furthermore, there is another locked session, indicating that the component might be about to be moved from one session to another.", e.getMessage()); + } finally { + VaadinSession.setCurrent(null); } } @@ -119,6 +121,8 @@ public class RemoveFromParentLockingTest { notLockedComponent.addComponent(lockedComponent); } catch (AssertionError e) { // All is fine, don't care about the exact wording in this case + } finally { + VaadinSession.setCurrent(null); } } -- 2.39.5