diff options
| author | Rafael H. Schloming <rhs@apache.org> | 2008-05-01 21:48:52 +0000 |
|---|---|---|
| committer | Rafael H. Schloming <rhs@apache.org> | 2008-05-01 21:48:52 +0000 |
| commit | b6b8e21d4b195d5a6fe30d784af5e9ab87eba8bc (patch) | |
| tree | bd5085e43973bc57692eaca8efc9fc0d38438c9a /qpid/java | |
| parent | a7a0c1ed22d99c302e6da2cbce010b9ff8ceea11 (diff) | |
| download | qpid-python-b6b8e21d4b195d5a6fe30d784af5e9ab87eba8bc.tar.gz | |
QPID-1002: applied patch from Senaka to make systests run using normal junit testrunner
git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk@652680 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'qpid/java')
| -rw-r--r-- | qpid/java/systests/src/main/java/org/apache/qpid/test/framework/FrameworkBaseCase.java | 7 | ||||
| -rw-r--r-- | qpid/java/systests/src/main/java/org/apache/qpid/test/framework/LocalCircuitFactory.java | 5 |
2 files changed, 10 insertions, 2 deletions
diff --git a/qpid/java/systests/src/main/java/org/apache/qpid/test/framework/FrameworkBaseCase.java b/qpid/java/systests/src/main/java/org/apache/qpid/test/framework/FrameworkBaseCase.java index 51b053d2b2..1050baaca6 100644 --- a/qpid/java/systests/src/main/java/org/apache/qpid/test/framework/FrameworkBaseCase.java +++ b/qpid/java/systests/src/main/java/org/apache/qpid/test/framework/FrameworkBaseCase.java @@ -23,9 +23,11 @@ package org.apache.qpid.test.framework; import org.apache.log4j.Logger; import org.apache.log4j.NDC; +import org.apache.qpid.server.registry.ApplicationRegistry; import org.apache.qpid.test.framework.BrokerLifecycleAware; import org.apache.qpid.test.framework.sequencers.CircuitFactory; +import org.apache.qpid.client.transport.TransportConnection; import org.apache.qpid.junit.extensions.AsymptoticTestCase; import org.apache.qpid.junit.extensions.SetupTaskAware; import org.apache.qpid.junit.extensions.SetupTaskHandler; @@ -54,7 +56,7 @@ public class FrameworkBaseCase extends AsymptoticTestCase implements FrameworkTe private static final Logger log = Logger.getLogger(FrameworkBaseCase.class); /** Holds the test sequencer to create and run test circuits with. */ - protected CircuitFactory circuitFactory = new LocalCircuitFactory(); + protected CircuitFactory circuitFactory = new LocalAMQPCircuitFactory(); /** Used to read the tests configurable properties through. */ protected ParsedProperties testProps; @@ -194,6 +196,7 @@ public class FrameworkBaseCase extends AsymptoticTestCase implements FrameworkTe testProps = TestContextProperties.getInstance(MessagingTestConfigProperties.defaults); // Process all optional setup tasks. This may include in-vm broker creation, if a decorator has added it. + TransportConnection.createVMBroker(1); taskHandler.runSetupTasks(); } @@ -205,6 +208,8 @@ public class FrameworkBaseCase extends AsymptoticTestCase implements FrameworkTe NDC.pop(); // Process all optional tear down tasks. This may include in-vm broker clean up, if a decorator has added it. + TransportConnection.killVMBroker(1); + ApplicationRegistry.remove(1); taskHandler.runTearDownTasks(); } diff --git a/qpid/java/systests/src/main/java/org/apache/qpid/test/framework/LocalCircuitFactory.java b/qpid/java/systests/src/main/java/org/apache/qpid/test/framework/LocalCircuitFactory.java index 68aad6ee47..84dd735d0d 100644 --- a/qpid/java/systests/src/main/java/org/apache/qpid/test/framework/LocalCircuitFactory.java +++ b/qpid/java/systests/src/main/java/org/apache/qpid/test/framework/LocalCircuitFactory.java @@ -68,7 +68,10 @@ public class LocalCircuitFactory implements CircuitFactory */ public void sequenceTest(Circuit testCircuit, List<Assertion> assertions, Properties testProperties) { - FrameworkBaseCase.assertNoFailures(testCircuit.test(1, assertions)); + if (testCircuit != null) + { + FrameworkBaseCase.assertNoFailures(testCircuit.test(1, assertions)); + } } /** |
