summaryrefslogtreecommitdiff
path: root/qpid/cpp/src
diff options
context:
space:
mode:
Diffstat (limited to 'qpid/cpp/src')
-rw-r--r--qpid/cpp/src/tests/brokertest.py3
-rwxr-xr-xqpid/cpp/src/tests/ha_tests.py14
-rw-r--r--qpid/cpp/src/tests/qpid-txtest.cpp1
3 files changed, 10 insertions, 8 deletions
diff --git a/qpid/cpp/src/tests/brokertest.py b/qpid/cpp/src/tests/brokertest.py
index c93a086301..ebb1702a05 100644
--- a/qpid/cpp/src/tests/brokertest.py
+++ b/qpid/cpp/src/tests/brokertest.py
@@ -218,6 +218,9 @@ class Popen(subprocess.Popen):
self._cleanup()
return ret
+ def assert_exit_ok(self):
+ if self.wait() != 0: self.unexpected("Exit code %d" % self.returncode)
+
def terminate(self):
try: subprocess.Popen.terminate(self)
except AttributeError: # No terminate method
diff --git a/qpid/cpp/src/tests/ha_tests.py b/qpid/cpp/src/tests/ha_tests.py
index 844856f718..de04c44481 100755
--- a/qpid/cpp/src/tests/ha_tests.py
+++ b/qpid/cpp/src/tests/ha_tests.py
@@ -1551,15 +1551,13 @@ class TransactionTests(HaBrokerTest):
for t in threads: t.join()
for s in sessions: s.connection.close()
- def test_broker_tx_tests(self):
+ def test_other_tx_tests(self):
cluster = HaCluster(self, 3)
- print "Running python broker tx tests"
- p = subprocess.Popen(["qpid-python-test",
- "-m", "qpid_tests.broker_0_10",
- "-b", "localhost:%s"%(cluster[0].port()),
- "*.tx.*"])
- assert not p.wait()
- print "Finished python broker tx tests"
+ self.popen(["qpid-txtest", "-p%s"%cluster[0].port()]).assert_exit_ok()
+ self.popen(["qpid-python-test",
+ "-m", "qpid_tests.broker_0_10",
+ "-b", "localhost:%s"%(cluster[0].port()),
+ "*.tx.*"]).assert_exit_ok()
if __name__ == "__main__":
outdir = "ha_tests.tmp"
diff --git a/qpid/cpp/src/tests/qpid-txtest.cpp b/qpid/cpp/src/tests/qpid-txtest.cpp
index 6e7d46802c..59ab905af7 100644
--- a/qpid/cpp/src/tests/qpid-txtest.cpp
+++ b/qpid/cpp/src/tests/qpid-txtest.cpp
@@ -179,6 +179,7 @@ struct Transfer : public Client, public Runnable
} else {
session.txCommit();
}
+ session.sync();
}
} catch(const std::exception& e) {
std::cout << "Transfer interrupted: " << e.what() << std::endl;