summaryrefslogtreecommitdiff
path: root/java
diff options
context:
space:
mode:
authorMartin Ritchie <ritchiem@apache.org>2010-06-02 16:42:54 +0000
committerMartin Ritchie <ritchiem@apache.org>2010-06-02 16:42:54 +0000
commita489a9d3def2adaa587e887cd6468cc500f152e2 (patch)
tree4fcff6b6e8ef421a5c7c3c6c5952f4b6a596b1ca /java
parent04b73758036cf8b6aac92174f192ce98fd2f3c92 (diff)
downloadqpid-python-a489a9d3def2adaa587e887cd6468cc500f152e2.tar.gz
QPID-2632 - Cleaned up PluginTest, it now simply uses the configure() method to set its additional property
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@950641 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'java')
-rw-r--r--java/broker/src/test/java/org/apache/qpid/server/plugins/PluginTest.java23
1 files changed, 5 insertions, 18 deletions
diff --git a/java/broker/src/test/java/org/apache/qpid/server/plugins/PluginTest.java b/java/broker/src/test/java/org/apache/qpid/server/plugins/PluginTest.java
index 325a4e6464..1ba03a2165 100644
--- a/java/broker/src/test/java/org/apache/qpid/server/plugins/PluginTest.java
+++ b/java/broker/src/test/java/org/apache/qpid/server/plugins/PluginTest.java
@@ -24,36 +24,23 @@ import org.apache.qpid.server.configuration.ServerConfiguration;
import org.apache.qpid.server.exchange.ExchangeType;
import org.apache.qpid.server.registry.ApplicationRegistry;
import org.apache.qpid.server.registry.IApplicationRegistry;
+import org.apache.qpid.server.util.InternalBrokerBaseCase;
import org.apache.qpid.server.util.TestApplicationRegistry;
import java.util.Map;
-public class PluginTest extends TestCase
+public class PluginTest extends InternalBrokerBaseCase
{
private static final String TEST_EXCHANGE_CLASS = "org.apache.qpid.extras.exchanges.example.TestExchangeType";
private static final String PLUGIN_DIRECTORY = System.getProperty("example.plugin.target");
private static final String CACHE_DIRECTORY = System.getProperty("example.cache.target");
- IApplicationRegistry _registry;
-
- @Override
- public void setUp() throws Exception
- {
- PropertiesConfiguration properties = new PropertiesConfiguration();
- properties.addProperty("plugin-directory", PLUGIN_DIRECTORY);
- properties.addProperty("cache-directory", CACHE_DIRECTORY);
- ServerConfiguration config = new ServerConfiguration(properties);
-
- // This Test requries an application Registry
- ApplicationRegistry.initialise(new TestApplicationRegistry(config));
- _registry = ApplicationRegistry.getInstance();
- }
-
@Override
- public void tearDown() throws Exception
+ public void configure()
{
- ApplicationRegistry.remove();
+ _configuration.getConfig().addProperty("plugin-directory", PLUGIN_DIRECTORY);
+ _configuration.getConfig().addProperty("cache-directory", CACHE_DIRECTORY);
}
public void disabled_testLoadExchanges() throws Exception