Converting tests to the new-style

This commit is contained in:
Joe Rickerby
2020-05-02 16:54:19 +01:00
parent c38bc9064a
commit 616e9dd6eb
62 changed files with 750 additions and 103 deletions
+24
View File
@@ -0,0 +1,24 @@
import ssl
import sys
from setuptools import (
Extension,
setup,
)
if sys.version_info[0] == 2:
from urllib2 import urlopen
else:
from urllib.request import urlopen
if sys.version_info[0:2] == (3, 3):
data = urlopen('https://www.nist.gov')
else:
context = ssl.SSLContext(ssl.PROTOCOL_TLSv1_2)
data = urlopen('https://www.nist.gov', context=context)
setup(
name="spam",
ext_modules=[Extension('spam', sources=['spam.c'])],
version="0.1.0",
)