diff options
| author | Alan Conway <aconway@apache.org> | 2009-11-17 18:09:21 +0000 |
|---|---|---|
| committer | Alan Conway <aconway@apache.org> | 2009-11-17 18:09:21 +0000 |
| commit | 8b58b19ec3989b676cd5a1584089040caee14289 (patch) | |
| tree | e0ca831f7fac0b26a4dcfa679b574e9a5dfafe06 /cpp/src/tests/cluster_tests.py | |
| parent | ef7728a725272b88c3cd2f81f81ee60ed00cde90 (diff) | |
| download | qpid-python-8b58b19ec3989b676cd5a1584089040caee14289.tar.gz | |
Integrated InitialStatusMap into cluster code.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@881423 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src/tests/cluster_tests.py')
| -rwxr-xr-x | cpp/src/tests/cluster_tests.py | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/cpp/src/tests/cluster_tests.py b/cpp/src/tests/cluster_tests.py index 637b0aea0f..3ded6c103e 100755 --- a/cpp/src/tests/cluster_tests.py +++ b/cpp/src/tests/cluster_tests.py @@ -29,6 +29,11 @@ from threading import Thread class ClusterTests(BrokerTest): """Cluster tests with support for testing with a store plugin.""" + def duration(self): + d = self.config.defines.get("DURATION") + if d: return float(d)*60 + else: return 3 + def test_message_replication(self): """Test basic cluster message replication.""" # Start a cluster, send some messages to member 0. @@ -66,11 +71,10 @@ class ClusterTests(BrokerTest): sender = NumberedSender(cluster[2]) sender.start() - # Kill original brokers, start new ones. - endtime = time.time() + (int(self.config.defines.get("DURATION") or 3)) + # Kill original brokers, start new ones for the duration. + endtime = time.time() + self.duration() i = 0 while time.time() < endtime: - print time.time(), endtime cluster[i].kill() i += 1 b = cluster.start(expect=EXPECT_EXIT_FAIL) |
