diff --git a/test/Makefile b/test/Makefile index c37ccf10..2ef45d6f 100644 --- a/test/Makefile +++ b/test/Makefile @@ -87,7 +87,11 @@ check-native-short: check-2.7-ok: $(PYTHON) test_pythonlib.py --ok-2.7 --verify $(COMPILE) -#: Run longer Python 2.7's lib files known to be okay +#: Run longer Python 3.2's lib files known to be okay +check-3.2-ok: + $(PYTHON) test_pythonlib.py --ok-3.2 --verify $(COMPILE) + +#: Run longer Python 3.4's lib files known to be okay check-3.4-ok: $(PYTHON) test_pythonlib.py --ok-3.4 --verify $(COMPILE) diff --git a/test/bytecode_3.5/06_classbug.pyc b/test/bytecode_3.5/06_classbug.pyc new file mode 100644 index 00000000..3ac3ab0e Binary files /dev/null and b/test/bytecode_3.5/06_classbug.pyc differ diff --git a/test/ok_lib2.7/_abcoll.pyc b/test/ok_lib2.7/_abcoll.pyc new file mode 100644 index 00000000..c9834c79 Binary files /dev/null and b/test/ok_lib2.7/_abcoll.pyc differ diff --git a/test/ok_lib2.7/_abcoll.pyo b/test/ok_lib2.7/_abcoll.pyo new file mode 100644 index 00000000..c9834c79 Binary files /dev/null and b/test/ok_lib2.7/_abcoll.pyo differ diff --git a/test/ok_lib2.7/antigravity.pyo b/test/ok_lib2.7/antigravity.pyo new file mode 100644 index 00000000..0e870e6d Binary files /dev/null and b/test/ok_lib2.7/antigravity.pyo differ diff --git a/test/ok_lib3.2/antigravity.cpython-32.pyc b/test/ok_lib3.2/antigravity.cpython-32.pyc new file mode 100644 index 00000000..d7969344 Binary files /dev/null and b/test/ok_lib3.2/antigravity.cpython-32.pyc differ diff --git a/test/ok_lib3.2/antigravity.cpython-32.pyo b/test/ok_lib3.2/antigravity.cpython-32.pyo new file mode 100644 index 00000000..d7969344 Binary files /dev/null and b/test/ok_lib3.2/antigravity.cpython-32.pyo differ diff --git a/test/simple_source/def/06_classbug.py b/test/simple_source/def/06_classbug.py new file mode 100644 index 00000000..6539b14b --- /dev/null +++ b/test/simple_source/def/06_classbug.py @@ -0,0 +1,13 @@ +# Python 3.2 Bug from abc.py + +# Make sure we handle: + +# LOAD_FAST '__locals__' +# STORE_LOCALS '' + +class abstractclassmethod(object): + """A Python 3.2 STORE_LOCALS bug + """ + + def __init__(self, callable): + callable.__isabstractmethod__ = True diff --git a/test/test_pythonlib.py b/test/test_pythonlib.py index 820c9384..cb937040 100755 --- a/test/test_pythonlib.py +++ b/test/test_pythonlib.py @@ -55,25 +55,28 @@ PYO = ('*.pyo', ) PYOC = ('*.pyc', '*.pyo') test_options = { - # name: (src_basedir, pattern, output_base_suffix, pythoin_version) + # name: (src_basedir, pattern, output_base_suffix, python_version) 'test': ('test', PYC, 'test'), 'ok-2.6': (os.path.join(src_dir, 'ok_2.6'), - PYC, 'ok-2.6', 2.6), + PYOC, 'ok-2.6', 2.6), 'ok-2.7': (os.path.join(src_dir, 'ok_lib2.7'), - PYC, 'ok-2.7', 2.7), + PYOC, 'ok-2.7', 2.7), + + 'ok-3.2': (os.path.join(src_dir, 'ok_lib3.2'), + PYOC, 'ok-3.2', 3.5), 'base-2.7': (os.path.join(src_dir, 'base_tests', 'python2.7'), - PYC, 'base_2.7', 2.7), + PYOC, 'base_2.7', 2.7), } -for vers in (2.7, 3.4): +for vers in (2.7, 3.4, 3.5): pythonlib = "ok_lib%s" % vers key = "ok-%s" % vers - test_options[key] = (os.path.join(src_dir, pythonlib), PYC, key, vers) + test_options[key] = (os.path.join(src_dir, pythonlib), PYOC, key, vers) pass for vers in (2.5, 2.6, 2.7, 3.2, 3.3, 3.4, 3.5): @@ -84,7 +87,7 @@ for vers in (2.5, 2.6, 2.7, 3.2, 3.3, 3.4, 3.5): pythonlib = "python%s" % vers if vers >= 3.0: pythonlib = os.path.join(pythonlib, '__pycache__') - test_options[key] = (os.path.join(lib_prefix, pythonlib), PYC, pythonlib, vers) + test_options[key] = (os.path.join(lib_prefix, pythonlib), PYOC, pythonlib, vers) #-----