From 35b2118013348d27e0943979907c1eae8d3cf843 Mon Sep 17 00:00:00 2001 From: Artur Signell Date: Tue, 11 Dec 2012 13:03:38 +0200 Subject: [PATCH] Fixed test Change-Id: I91e3492f3243d5d789a6608981646bc3217adb53 --- .../vaadin/tests/server/TestStreamVariableMapping.java | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/server/tests/src/com/vaadin/tests/server/TestStreamVariableMapping.java b/server/tests/src/com/vaadin/tests/server/TestStreamVariableMapping.java index f24638e6a7..250fa3f771 100644 --- a/server/tests/src/com/vaadin/tests/server/TestStreamVariableMapping.java +++ b/server/tests/src/com/vaadin/tests/server/TestStreamVariableMapping.java @@ -50,16 +50,17 @@ public class TestStreamVariableMapping extends TestCase { public void testAddStreamVariable() { String targetUrl = cm.getStreamVariableTargetUrl(owner, variableName, streamVariable); - assertTrue(targetUrl.startsWith("app://APP/UPLOAD/-1/1/myName/")); + assertTrue(targetUrl.startsWith("app://APP/UPLOAD/-1/" + + owner.getConnectorId() + "/myName/")); - ConnectorTracker tracker = UI.getCurrent().getConnectorTracker(); + ConnectorTracker tracker = owner.getUI().getConnectorTracker(); StreamVariable streamVariable2 = tracker.getStreamVariable( owner.getConnectorId(), variableName); assertSame(streamVariable, streamVariable2); } - public void testRemoverVariable() { - ConnectorTracker tracker = UI.getCurrent().getConnectorTracker(); + public void testRemoveVariable() { + ConnectorTracker tracker = owner.getUI().getConnectorTracker(); cm.getStreamVariableTargetUrl(owner, variableName, streamVariable); assertNotNull(tracker.getStreamVariable(owner.getConnectorId(), variableName)); -- 2.39.5