From 194a3ce1ab546d8897c8532be4d9eace121f4191 Mon Sep 17 00:00:00 2001 From: Alan Conway Date: Wed, 4 Aug 2010 19:25:28 +0000 Subject: Fix ClusterFailover.cpp and ForkedBroker.cpp to avoid using the default data directory. Was causing tests to fail because of a pre-existing lock file in the default data dir. git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@982374 13f79535-47bb-0310-9956-ffa450edef68 --- cpp/src/tests/ClusterFailover.cpp | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) (limited to 'cpp/src/tests/ClusterFailover.cpp') diff --git a/cpp/src/tests/ClusterFailover.cpp b/cpp/src/tests/ClusterFailover.cpp index 06fc1c06be..bf5c147f19 100644 --- a/cpp/src/tests/ClusterFailover.cpp +++ b/cpp/src/tests/ClusterFailover.cpp @@ -50,9 +50,15 @@ using boost::shared_ptr; // Timeout for tests that wait for messages const sys::Duration TIMEOUT=sys::TIME_SEC/4; -ClusterFixture::Args getArgs() { +ClusterFixture::Args getArgs(bool durable=std::getenv("STORE_LIB")) +{ ClusterFixture::Args args; - args += "--auth", "no", "--no-module-dir", "--load-module", getLibPath("CLUSTER_LIB"); + args += "--auth", "no", "--no-module-dir", + "--load-module", getLibPath("CLUSTER_LIB"); + if (durable) + args += "--load-module", getLibPath("STORE_LIB"), "TMP_DATA_DIR"; + else + args += "--no-data-dir"; return args; } @@ -87,7 +93,7 @@ QPID_AUTO_TEST_CASE(testReconnectExclusiveQueue) { // Regression: core dump on exit if unacked messages were left in // a session with a timeout. - cluster.kill(0); + cluster.killWithSilencer(0, c0.connection); // Regression: session timeouts prevented re-connecting to // exclusive queue. -- cgit v1.2.1