Use a subtest in test_ssl.test_echo

This commit is contained in:
Antoine Pitrou 2013-03-29 17:56:03 +01:00
parent 22e162f462
commit 972d5bb763
1 changed files with 5 additions and 4 deletions

View File

@ -1385,10 +1385,11 @@ else:
if support.verbose:
sys.stdout.write("\n")
for protocol in PROTOCOLS:
context = ssl.SSLContext(protocol)
context.load_cert_chain(CERTFILE)
server_params_test(context, context,
chatty=True, connectionchatty=True)
with self.subTest(protocol=ssl._PROTOCOL_NAMES[protocol]):
context = ssl.SSLContext(protocol)
context.load_cert_chain(CERTFILE)
server_params_test(context, context,
chatty=True, connectionchatty=True)
def test_getpeercert(self):
if support.verbose: