Clean up and strip down netstrings module.

This commit is contained in:
Aldo Cortesi
2011-02-20 14:03:32 +13:00
parent 7ddba22f51
commit aa16194518
3 changed files with 13 additions and 98 deletions

View File

@@ -342,8 +342,10 @@ def dummy_ca(path):
stdout=subprocess.PIPE,
stdin=subprocess.PIPE
)
# begin nocover
if ret:
return False
# end nocover
else:
return True
@@ -382,8 +384,7 @@ def dummy_cert(certdir, ca, commonname):
stdout=subprocess.PIPE,
stdin=subprocess.PIPE
)
if ret:
return None
if ret: return None
cmd = [
"openssl",
"x509",
@@ -402,8 +403,7 @@ def dummy_cert(certdir, ca, commonname):
stdout=subprocess.PIPE,
stdin=subprocess.PIPE
)
if ret:
return None
if ret: return None
else:
# Create a new selfsigned certificate + key
cmd = [
@@ -424,8 +424,7 @@ def dummy_cert(certdir, ca, commonname):
stdout=subprocess.PIPE,
stdin=subprocess.PIPE
)
if ret:
return None
if ret: return None
return certpath
@@ -437,5 +436,3 @@ def mkdir_p(path):
pass
else:
raise