You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@qpid.apache.org by ac...@apache.org on 2017/06/09 01:25:34 UTC

[11/50] [abbrv] qpid-proton git commit: PROTON-1476: Reinstate C++ scheduled_send tests and remove unused mt tests

PROTON-1476: Reinstate C++ scheduled_send tests and remove unused mt tests


Project: http://git-wip-us.apache.org/repos/asf/qpid-proton/repo
Commit: http://git-wip-us.apache.org/repos/asf/qpid-proton/commit/2b5cfc81
Tree: http://git-wip-us.apache.org/repos/asf/qpid-proton/tree/2b5cfc81
Diff: http://git-wip-us.apache.org/repos/asf/qpid-proton/diff/2b5cfc81

Branch: refs/heads/go1
Commit: 2b5cfc817cbdc3dea496a3da9bb66a8f0e4ab000
Parents: 81ba5a3
Author: Andrew Stitcher <as...@apache.org>
Authored: Fri May 12 11:59:01 2017 -0400
Committer: Andrew Stitcher <as...@apache.org>
Committed: Fri May 12 12:02:42 2017 -0400

----------------------------------------------------------------------
 examples/cpp/example_test.py | 74 ++++++++-------------------------------
 1 file changed, 14 insertions(+), 60 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/qpid-proton/blob/2b5cfc81/examples/cpp/example_test.py
----------------------------------------------------------------------
diff --git a/examples/cpp/example_test.py b/examples/cpp/example_test.py
index a80ee5c..f9a0825 100644
--- a/examples/cpp/example_test.py
+++ b/examples/cpp/example_test.py
@@ -210,6 +210,20 @@ map{string(k1):int(42), symbol(k2):boolean(0)}
         self.maxDiff = None
         self.assertEqual(want, self.proc(["encode_decode"]).wait_exit())
 
+    def test_scheduled_send_03(self):
+        # Output should be a bunch of "send" lines but can't guarantee exactly how many.
+        out = self.proc(["scheduled_send_03", "-a", self.addr+"scheduled_send", "-t", "0.1", "-i", "0.001"]).wait_exit().split()
+        self.assertTrue(len(out) > 0);
+        self.assertEqual(["send"]*len(out), out)
+
+    def test_scheduled_send(self):
+        try:
+            out = self.proc(["scheduled_send", "-a", self.addr+"scheduled_send", "-t", "0.1", "-i", "0.001"]).wait_exit().split()
+            self.assertTrue(len(out) > 0);
+            self.assertEqual(["send"]*len(out), out)
+        except ProcError:       # File not found, not a C++11 build.
+            pass
+
 
 class ContainerExampleSSLTest(BrokerTestCase):
     """Run the SSL container examples, verify they behave as expected."""
@@ -273,65 +287,5 @@ Hello World!
             expect_found = (out.find(expect) >= 0)
             self.assertEqual(expect_found, True)
 
-    def test_scheduled_send_03(self):
-        # Output should be a bunch of "send" lines but can't guarantee exactly how many.
-        out = self.proc(["scheduled_send_03", "-a", self.addr+"scheduled_send", "-t", "0.1", "-i", "0.001"]).wait_exit().split()
-        self.assertTrue(len(out) > 0);
-        self.assertEqual(["send"]*len(out), out)
-
-    def test_scheduled_send(self):
-        try:
-            out = self.proc(["scheduled_send", "-a", self.addr+"scheduled_send", "-t", "0.1", "-i", "0.001"]).wait_exit().split()
-            self.assertTrue(len(out) > 0);
-            self.assertEqual(["send"]*len(out), out)
-        except ProcError:       # File not found, not a C++11 build.
-            pass
-
-
-class EngineTestCase(BrokerTestCase):
-    """Run selected clients to test a connction_engine broker."""
-
-    def test_helloworld(self):
-        self.assertEqual('Hello World!\n',
-                         self.proc(["helloworld", self.addr]).wait_exit())
-
-    def test_simple_send_recv(self):
-        self.assertEqual("all messages confirmed\n",
-                         self.proc(["simple_send", "-a", self.addr]).wait_exit())
-        self.assertEqual(recv_expect("simple_recv", self.addr), self.proc(["simple_recv", "-a", self.addr]).wait_exit())
-
-    def test_simple_recv_send(self):
-        # Start receiver first, then run sender"""
-        recv = self.proc(["simple_recv", "-a", self.addr])
-        self.assertEqual("all messages confirmed\n", self.proc(["simple_send", "-a", self.addr]).wait_exit())
-        self.assertEqual(recv_expect("simple_recv", self.addr), recv.wait_exit())
-
-
-    def test_simple_send_direct_recv(self):
-        with TestPort() as tp:
-            addr = "%s/examples" % tp.addr
-            recv = self.proc(["direct_recv", "-a", addr], "listening")
-            self.assertEqual("all messages confirmed\n",
-                             self.proc(["simple_send", "-a", addr]).wait_exit())
-            self.assertEqual(recv_expect("direct_recv", addr), recv.wait_exit())
-
-    def test_simple_recv_direct_send(self):
-        with TestPort() as tp:
-            addr = "%s/examples" % tp.addr
-            send = self.proc(["direct_send", "-a", tp.addr], "listening")
-            self.assertEqual(recv_expect("simple_recv", addr),
-                             self.proc(["simple_recv", "-a", addr]).wait_exit())
-            self.assertEqual("direct_send listening on %s\nall messages confirmed\n" % addr,
-                             send.wait_exit())
-
-    def test_request_response(self):
-        server = self.proc(["server", "-a", self.addr], "connected")
-        self.assertEqual(CLIENT_EXPECT,
-                         self.proc(["client", "-a", self.addr]).wait_exit())
-
-
-class MtBrokerTest(EngineTestCase):
-    broker_exe = "mt_broker"
-
 if __name__ == "__main__":
     unittest.main()


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@qpid.apache.org
For additional commands, e-mail: commits-help@qpid.apache.org