diff options
| author | Robert Gemmell <robbie@apache.org> | 2010-02-25 17:18:57 +0000 |
|---|---|---|
| committer | Robert Gemmell <robbie@apache.org> | 2010-02-25 17:18:57 +0000 |
| commit | c8310f80c59024051530cbac19323c423f6c7785 (patch) | |
| tree | 438a2b4e6b8873aef07e4a1eba18997888fbf7d5 /java | |
| parent | dcfef7071cf174ce3c766198d995255fc7b13d8b (diff) | |
| download | qpid-python-c8310f80c59024051530cbac19323c423f6c7785.tar.gz | |
QPID-2417: add ability to run DurableSubscriberTest on the java-derby profile once QPID-2422 is fixed
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@916358 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'java')
4 files changed, 11 insertions, 2 deletions
diff --git a/java/module.xml b/java/module.xml index 820f7ce036..96401f2178 100644 --- a/java/module.xml +++ b/java/module.xml @@ -273,6 +273,7 @@ <sysproperty key="broker" value="${broker}"/> <sysproperty key="broker.clean" value="${broker.clean}"/> <sysproperty key="broker.clean.between.tests" value="${broker.clean.between.tests}"/> + <sysproperty key="broker.persistent" value="${broker.persistent}"/> <sysproperty key="broker.version" value="${broker.version}"/> <sysproperty key="broker.ready" value="${broker.ready}" /> <sysproperty key="broker.stopped" value="${broker.stopped}" /> diff --git a/java/systests/src/main/java/org/apache/qpid/test/unit/ct/DurableSubscriberTest.java b/java/systests/src/main/java/org/apache/qpid/test/unit/ct/DurableSubscriberTest.java index 19b73fcc7c..cf815fbc05 100644 --- a/java/systests/src/main/java/org/apache/qpid/test/unit/ct/DurableSubscriberTest.java +++ b/java/systests/src/main/java/org/apache/qpid/test/unit/ct/DurableSubscriberTest.java @@ -38,7 +38,7 @@ public class DurableSubscriberTest extends QpidTestCase */ public void testDurSubRestoredAfterNonPersistentMessageSent() throws Exception { - if (!isBroker08()) + if (isBrokerStorePersistent() || !isBroker08()) { TopicConnectionFactory factory = getConnectionFactory(); Topic topic = (Topic) getInitialContext().lookup(_topicName); @@ -102,7 +102,7 @@ public class DurableSubscriberTest extends QpidTestCase */ public void testDurSubRestoresMessageSelector() throws Exception { - if (!isBroker08()) + if (isBrokerStorePersistent() || !isBroker08()) { TopicConnectionFactory factory = getConnectionFactory(); Topic topic = (Topic) getInitialContext().lookup(_topicName); diff --git a/java/systests/src/main/java/org/apache/qpid/test/utils/QpidTestCase.java b/java/systests/src/main/java/org/apache/qpid/test/utils/QpidTestCase.java index 84ff7055c5..d693c7f6c1 100644 --- a/java/systests/src/main/java/org/apache/qpid/test/utils/QpidTestCase.java +++ b/java/systests/src/main/java/org/apache/qpid/test/utils/QpidTestCase.java @@ -166,6 +166,7 @@ public class QpidTestCase extends TestCase private static final String TEST_OUTPUT = "test.output"; private static final String BROKER_LOG_INTERLEAVE = "broker.log.interleave"; private static final String BROKER_LOG_PREFIX = "broker.log.prefix"; + private static final String BROKER_PERSITENT = "broker.persistent"; // values protected static final String JAVA = "java"; @@ -187,6 +188,7 @@ public class QpidTestCase extends TestCase private Boolean _brokerCleanBetweenTests = Boolean.getBoolean(BROKER_CLEAN_BETWEEN_TESTS); private String _brokerVersion = System.getProperty(BROKER_VERSION, VERSION_08); private String _output = System.getProperty(TEST_OUTPUT); + protected Boolean _brokerPersistent = Boolean.getBoolean(BROKER_PERSITENT); private static String _brokerLogPrefix = System.getProperty(BROKER_LOG_PREFIX,"BROKER: "); protected static boolean _interleaveBrokerLog = Boolean.getBoolean(BROKER_LOG_INTERLEAVE); @@ -929,6 +931,11 @@ public class QpidTestCase extends TestCase { return !_broker.equals("vm"); } + + protected boolean isBrokerStorePersistent() + { + return _brokerPersistent; + } public void restartBroker() throws Exception { diff --git a/java/test-profiles/java-derby.testprofile b/java/test-profiles/java-derby.testprofile index 1238a44c84..618dd5b45d 100644 --- a/java/test-profiles/java-derby.testprofile +++ b/java/test-profiles/java-derby.testprofile @@ -7,3 +7,4 @@ broker.config=${project.root}/build/etc/config-systests-derby.xml qpid.amqp.version=0-9 profile.excludes=JavaStandaloneExcludes broker.clean.between.tests=true +broker.persistent=true |
