diff --git a/tests/gold_tests/autest-site/copy_config.test.ext b/tests/gold_tests/autest-site/copy_config.test.ext index 72a9ba6da21..d7102402ee0 100755 --- a/tests/gold_tests/autest-site/copy_config.test.ext +++ b/tests/gold_tests/autest-site/copy_config.test.ext @@ -34,7 +34,7 @@ class CopyATSConfig(SetupItem): process = self.process if self.process else self try: ts_dir = process.Env['TS_ROOT'] - except: + except BaseException: if self.process: raise SetupError( 'TS_ROOT is not defined. Cannot copy ats config file without location to copy to.' diff --git a/tests/gold_tests/autest-site/microserver.test.ext b/tests/gold_tests/autest-site/microserver.test.ext index 5be699b9883..e5c9c25f669 100644 --- a/tests/gold_tests/autest-site/microserver.test.ext +++ b/tests/gold_tests/autest-site/microserver.test.ext @@ -59,8 +59,14 @@ def getHeaderFieldVal(request_header, field): # addResponse adds customized response with respect to request_header. request_header and response_header are both dictionaries def addResponse(self, filename, request_header, response_header): - client_request = Request.fromRequestLine(request_header["headers"], request_header["body"], None if "options" not in request_header else request_header["options"]) - server_response = Response.fromRequestLine(response_header["headers"], response_header["body"], None if "options" not in response_header else response_header["options"]) + client_request = Request.fromRequestLine( + request_header["headers"], + request_header["body"], + None if "options" not in request_header else request_header["options"]) + server_response = Response.fromRequestLine( + response_header["headers"], + response_header["body"], + None if "options" not in response_header else response_header["options"]) # timestamp field is left None because that needs to be revised for better implementation txn = Transaction(client_request, None, server_response, None, None, None) diff --git a/tests/gold_tests/autest-site/trafficserver.test.ext b/tests/gold_tests/autest-site/trafficserver.test.ext index 423af0f1cf1..8c3a7e4f5ed 100755 --- a/tests/gold_tests/autest-site/trafficserver.test.ext +++ b/tests/gold_tests/autest-site/trafficserver.test.ext @@ -63,7 +63,7 @@ def MakeATSProcess(obj, name, command='traffic_server', select_ports=True, enabl p = obj.Processes.Process(name, command) #p_debug = obj.Processes.Process("port-debug", "ss --listen --tcp --process") #p_debug.Env['PATH'] = "/usr/sbin" + os.pathsep + p.ComposeEnv()['PATH'] - #p.StartBefore(p_debug) + # p.StartBefore(p_debug) # we want to have a few directories more fixed # this helps with debugging as location are common # we do this by overiding locations from the "layout" @@ -289,7 +289,8 @@ def MakeATSProcess(obj, name, command='traffic_server', select_ports=True, enabl port_str = "{port} {v6_port}:ipv6 ".format(port=p.Variables.port, v6_port=p.Variables.portv6) if enable_tls: - port_str += "{ssl_port}:ssl {ssl_portv6}:ssl:ipv6".format(ssl_port=p.Variables.ssl_port,ssl_portv6=p.Variables.ssl_portv6) + port_str += "{ssl_port}:ssl {ssl_portv6}:ssl:ipv6".format( + ssl_port=p.Variables.ssl_port, ssl_portv6=p.Variables.ssl_portv6) p.Env['PROXY_CONFIG_HTTP_SERVER_PORTS'] = port_str diff --git a/tests/gold_tests/command_argument/verify_remap_plugin.test.py b/tests/gold_tests/command_argument/verify_remap_plugin.test.py index dcd062d6c64..2a7bcc7b2c7 100644 --- a/tests/gold_tests/command_argument/verify_remap_plugin.test.py +++ b/tests/gold_tests/command_argument/verify_remap_plugin.test.py @@ -98,7 +98,8 @@ def create_ts_process(): tr.Processes.Default.Streams.stderr = Testers.ContainsExpression( "ERROR: .*missing required function TSRemapInit", "Should warn about the need for the TSRemapInit symbol") -ts.Disk.diags_log.Content = Testers.ContainsExpression("ERROR", +ts.Disk.diags_log.Content = Testers.ContainsExpression( + "ERROR", "ERROR: .*missing required function TSRemapInit") @@ -121,7 +122,8 @@ def create_ts_process(): tr.Processes.Default.Streams.stderr = Testers.ContainsExpression( "ERROR: .*missing required function TSRemapInit", "Should warn about the need for the TSRemapInit symbol") -ts.Disk.diags_log.Content = Testers.ContainsExpression("ERROR", +ts.Disk.diags_log.Content = Testers.ContainsExpression( + "ERROR", "ERROR: .*missing required function TSRemapInit") diff --git a/tests/gold_tests/continuations/double.test.py b/tests/gold_tests/continuations/double.test.py index d81582d72a5..dd13f9fe44e 100644 --- a/tests/gold_tests/continuations/double.test.py +++ b/tests/gold_tests/continuations/double.test.py @@ -56,7 +56,7 @@ # add plugin to assist with test metrics Test.PrepareTestPlugin(os.path.join(Test.Variables.AtsTestPluginsDir, - 'continuations_verify.so'), ts) + 'continuations_verify.so'), ts) comparator_command = ''' if test "`traffic_ctl metric get continuations_verify.{0}.close.1 | cut -d ' ' -f 2`" -eq "`traffic_ctl metric get continuations_verify.{0}.close.2 | cut -d ' ' -f 2`" ; then\ diff --git a/tests/gold_tests/continuations/double_h2.test.py b/tests/gold_tests/continuations/double_h2.test.py index ea76492f3dc..cf046a847a4 100644 --- a/tests/gold_tests/continuations/double_h2.test.py +++ b/tests/gold_tests/continuations/double_h2.test.py @@ -66,7 +66,7 @@ # add plugin to assist with test metrics Test.PrepareTestPlugin(os.path.join(Test.Variables.AtsTestPluginsDir, - 'continuations_verify.so'), ts) + 'continuations_verify.so'), ts) comparator_command = ''' if test "`traffic_ctl metric get continuations_verify.{0}.close.1 | cut -d ' ' -f 2`" -eq "`traffic_ctl metric get continuations_verify.{0}.close.2 | cut -d ' ' -f 2`" ; then\ diff --git a/tests/gold_tests/continuations/openclose.test.py b/tests/gold_tests/continuations/openclose.test.py index ee66f222aba..7b88420af3b 100644 --- a/tests/gold_tests/continuations/openclose.test.py +++ b/tests/gold_tests/continuations/openclose.test.py @@ -36,7 +36,7 @@ "timestamp": "1469733493.993", "body": ""} Test.PrepareTestPlugin(os.path.join(Test.Variables.AtsTestPluginsDir, - 'ssntxnorder_verify.so'), ts) + 'ssntxnorder_verify.so'), ts) # add response to the server dictionary server.addResponse("sessionfile.log", request_header, response_header) diff --git a/tests/gold_tests/continuations/openclose_h2.test.py b/tests/gold_tests/continuations/openclose_h2.test.py index db5ba69ce0b..7c62de94261 100644 --- a/tests/gold_tests/continuations/openclose_h2.test.py +++ b/tests/gold_tests/continuations/openclose_h2.test.py @@ -44,7 +44,7 @@ ts.addSSLfile("ssl/server.key") Test.PrepareTestPlugin(os.path.join(Test.Variables.AtsTestPluginsDir, - 'ssntxnorder_verify.so'), ts) + 'ssntxnorder_verify.so'), ts) # add response to the server dictionary server.addResponse("sessionfile.log", request_header, response_header) diff --git a/tests/gold_tests/tls/tls_hooks_verify.test.py b/tests/gold_tests/tls/tls_hooks_verify.test.py index 44dc888c707..70e26a85c3f 100644 --- a/tests/gold_tests/tls/tls_hooks_verify.test.py +++ b/tests/gold_tests/tls/tls_hooks_verify.test.py @@ -65,7 +65,12 @@ ts.Disk.sni_yaml.AddLine( ' verify_server_policy: PERMISSIVE') -Test.PrepareTestPlugin(os.path.join(Test.Variables.AtsTestPluginsDir, 'ssl_verify_test.so'), ts, '-count=2 -bad=random.com -bad=bar.com') +Test.PrepareTestPlugin( + os.path.join( + Test.Variables.AtsTestPluginsDir, + 'ssl_verify_test.so'), + ts, + '-count=2 -bad=random.com -bad=bar.com') tr = Test.AddTestRun("request good name") tr.Processes.Default.StartBefore(server)