You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@qpid.apache.org by "ASF GitHub Bot (Jira)" <ji...@apache.org> on 2021/11/29 16:32:00 UTC

[jira] [Commented] (PROTON-2471) Run raw connection examples during proton-c examples test

    [ https://issues.apache.org/jira/browse/PROTON-2471?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17450578#comment-17450578 ] 

ASF GitHub Bot commented on PROTON-2471:
----------------------------------------

jiridanek commented on a change in pull request #345:
URL: https://github.com/apache/qpid-proton/pull/345#discussion_r758534117



##########
File path: c/examples/testme
##########
@@ -107,5 +112,41 @@ class ExampleTest(unittest.TestCase):
             else:
                 raise
 
+    def test_raw_connect(self):
+        message = b"At thee! Have at thee!\n"
+
+        with Server(["raw_echo", "", "0"], kill_me=True) as server:
+            client = subprocess.Popen(args=["raw_connect", "", server.port],
+                                      stdin=subprocess.PIPE, stdout=subprocess.PIPE)
+            client.stdin.write(message)
+            client.stdin.flush()
+            stdout, _ = client.communicate()
+
+            expected_brief = b'**raw connection connected\n' + message + b'**raw connection disconnected\n'
+            expected_polite = b'**raw connection connected\n' + message + b'** Goodbye ****raw connection disconnected\n'
+
+            expected = expected_polite if b'Goodbye' in stdout else expected_brief

Review comment:
       I'm at a loss how to get deterministic output from the example. Sometimes it manages to receive and print that Goodbye, but oftentimes not.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@qpid.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


> Run raw connection examples during proton-c examples test
> ---------------------------------------------------------
>
>                 Key: PROTON-2471
>                 URL: https://issues.apache.org/jira/browse/PROTON-2471
>             Project: Qpid Proton
>          Issue Type: Test
>          Components: examples, proton-c
>    Affects Versions: proton-c-0.36.0
>            Reporter: Jiri Daněk
>            Assignee: Jiri Daněk
>            Priority: Major
>             Fix For: proton-c-0.37.0
>
>




--
This message was sent by Atlassian Jira
(v8.20.1#820001)

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