jiridanek commented on a change in pull request #1212:
URL: https://github.com/apache/qpid-dispatch/pull/1212#discussion_r630520991



##########
File path: tests/system_tests_bad_configuration.py
##########
@@ -109,15 +109,23 @@ def wait_for_unresolvable_host(self):
         then it stops scheduling new attempts.
         :return:
         """
-        with open(self.router.logfile_path, 'r') as router_log:
-            log_lines = router_log.read().split("\n")
-            expected_log_snip = "Connection to %s" % 
self.unresolvable_host_name
-            errors_caught = [line for line in log_lines if expected_log_snip 
in line and "failed" in line]
-
-            self.error_caught = any(errors_caught)
-
-            # If condition not yet satisfied and not exhausted max attempts,
-            # re-schedule the verification.
+        try:
+            with open(self.router.logfile_path, 'r') as router_log:

Review comment:
       It's better to open file with 'rt', for Python 3 (and Windows :P)




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