ganeshmurthy commented on a change in pull request #979:
URL: https://github.com/apache/qpid-dispatch/pull/979#discussion_r556838348



##########
File path: tests/system_tests_ssl.py
##########
@@ -452,6 +458,76 @@ def get_expected_tls_result(self, expected_results):
                 self.OPENSSL_ALLOW_TLSV1_2 and tlsv1_2,
                 self.OPENSSL_ALLOW_TLSV1_3 and tlsv1_3]
 
+    def inject_file(self, source_file, dest_file):
+        source_path = self.ssl_file(source_file)
+        url         = Url("amqp://0.0.0.0:%d" % self.PORT_CLEAR)
+        try:
+            connection = BlockingConnection(url, sasl_enabled=False, 
timeout=self.TIMEOUT)
+            sender     = connection.create_sender('_$qd.store_file')
+            fd         = open(source_path, "r")
+            body       = fd.read()
+            fd.close()
+            sender.send(Message(subject=dest_file, body=body))

Review comment:
       Instead of calling this inject_file three times, why not send a message 
with a body as a dict. 




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to