diff options
author | Marnie McCormack <marnie@apache.org> | 2006-11-07 12:31:17 +0000 |
---|---|---|
committer | Marnie McCormack <marnie@apache.org> | 2006-11-07 12:31:17 +0000 |
commit | 0862c9c93cc2aaf3905846af1f9fe8444bf01f02 (patch) | |
tree | fe95d5f602aec482423b080639d1ade84fb7a102 | |
parent | ffa8c607996d8019682e5b63f23653483044e46d (diff) | |
download | qpid-python-0862c9c93cc2aaf3905846af1f9fe8444bf01f02.tar.gz |
Before/After now class level
git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk/qpid/java@472083 13f79535-47bb-0310-9956-ffa450edef68
-rw-r--r-- | client/test/src/org/apache/qpid/client/TestAMQSession.java | 21 |
1 files changed, 9 insertions, 12 deletions
diff --git a/client/test/src/org/apache/qpid/client/TestAMQSession.java b/client/test/src/org/apache/qpid/client/TestAMQSession.java index bae3a4fb08..3f2457f682 100644 --- a/client/test/src/org/apache/qpid/client/TestAMQSession.java +++ b/client/test/src/org/apache/qpid/client/TestAMQSession.java @@ -17,10 +17,7 @@ */
package org.apache.qpid.client;
-import org.junit.Before;
-import org.junit.Test;
-import org.junit.Assert;
-import org.junit.After;
+import org.junit.*;
import org.apache.qpid.AMQException;
import org.apache.qpid.client.transport.TransportConnection;
import org.apache.qpid.client.vmbroker.AMQVMBrokerCreationException;
@@ -37,12 +34,12 @@ import junit.framework.JUnit4TestAdapter; */
public class TestAMQSession {
- private AMQSession _session;
- private AMQTopic _topic;
- private AMQQueue _queue;
+ private static AMQSession _session;
+ private static AMQTopic _topic;
+ private static AMQQueue _queue;
- @Before
- public void setUp() throws AMQException, URLSyntaxException, JMSException {
+ @BeforeClass
+ public static void setUp() throws AMQException, URLSyntaxException, JMSException {
//initialise the variables we need for testing
startVmBrokers();
AMQConnection connection = new AMQConnection("vm://:1", "guest", "guest", "fred", "/test");
@@ -87,8 +84,8 @@ public class TestAMQSession { Assert.assertEquals("Queue names should match from QueueReceiver with selector",_queue.getQueueName(),receiver.getQueue().getQueueName());
}
- @After
- public void stopVmBrokers()
+ @AfterClass
+ public static void stopVmBrokers()
{
TransportConnection.killVMBroker(1);
_queue = null;
@@ -101,7 +98,7 @@ public class TestAMQSession { return new JUnit4TestAdapter(TestAMQSession.class);
}
- private void startVmBrokers()
+ private static void startVmBrokers()
{
try
{
|