From 3d34526bc2fe159b265d5a7c58ffd687ba00c499 Mon Sep 17 00:00:00 2001 From: Robert Godfrey Date: Sun, 20 Apr 2014 01:32:50 +0000 Subject: QPID-5712 : [Java Broker] Remove VirtualHostRegistry and remove redundant maps from BrokerAdapter git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@1588715 13f79535-47bb-0310-9956-ffa450edef68 --- .../org/apache/qpid/server/store/berkeleydb/VirtualHostTest.java | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'qpid/java/bdbstore/src/test') diff --git a/qpid/java/bdbstore/src/test/java/org/apache/qpid/server/store/berkeleydb/VirtualHostTest.java b/qpid/java/bdbstore/src/test/java/org/apache/qpid/server/store/berkeleydb/VirtualHostTest.java index 3e23df6d87..5ad113f827 100644 --- a/qpid/java/bdbstore/src/test/java/org/apache/qpid/server/store/berkeleydb/VirtualHostTest.java +++ b/qpid/java/bdbstore/src/test/java/org/apache/qpid/server/store/berkeleydb/VirtualHostTest.java @@ -59,6 +59,7 @@ public class VirtualHostTest extends QpidTestCase private File _bdbStorePath; private VirtualHost _host; private ConfigurationEntryStore _store; + private TaskExecutor _taskExecutor; @Override protected void setUp() throws Exception @@ -67,9 +68,9 @@ public class VirtualHostTest extends QpidTestCase _store = mock(ConfigurationEntryStore.class); _broker = BrokerTestHelper.createBrokerMock(); - TaskExecutor taslExecutor = mock(TaskExecutor.class); - when(taslExecutor.isTaskExecutorThread()).thenReturn(true); - when(_broker.getTaskExecutor()).thenReturn(taslExecutor); + _taskExecutor = new TaskExecutor(); + _taskExecutor.start(); + when(_broker.getTaskExecutor()).thenReturn(_taskExecutor); _statisticsGatherer = mock(StatisticsGatherer.class); @@ -89,6 +90,8 @@ public class VirtualHostTest extends QpidTestCase } finally { + _taskExecutor.stopImmediately(); + if (_bdbStorePath != null) { FileUtils.delete(_bdbStorePath, true); -- cgit v1.2.1