diff options
| author | Felix Yan <felixonmars@gmail.com> | 2015-08-20 16:24:31 +0800 |
|---|---|---|
| committer | Felix Yan <felixonmars@gmail.com> | 2015-08-20 16:24:31 +0800 |
| commit | 931258a53042680b526e28b3fc0224e61582e51d (patch) | |
| tree | 98d1d8346cea9e38b43df099802ca9188d8cd5a8 | |
| parent | f7df76922e2025836998017df83c6ac4b5c22741 (diff) | |
| download | cffi-fix-zdist-test.tar.gz | |
fix python 3.x compatibility for test_zdistfix-zdist-test
| -rw-r--r-- | testing/cffi1/test_zdist.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/testing/cffi1/test_zdist.py b/testing/cffi1/test_zdist.py index f2d64d2..1b2c6a0 100644 --- a/testing/cffi1/test_zdist.py +++ b/testing/cffi1/test_zdist.py @@ -320,19 +320,20 @@ class TestDist(object): ffi._hi_there = 42 """) with open("setup.py", "w") as f: - f.write("""if 1: + f.write("from __future__ import print_function\n" + """if 1: from setuptools import setup from distutils.command.build_ext import build_ext import os class TestBuildExt(build_ext): def pre_run(self, ext, ffi): - print '_make_setuptools_api: in pre_run:', + print('_make_setuptools_api: in pre_run:', end=" ") assert ffi._hi_there == 42 assert ext.name == "pack3.mymod" fn = os.path.join(os.path.dirname(self.build_lib), '..', 'see_me') - print 'creating %r' % (fn,) + print('creating %r' % (fn,)) open(fn, 'w').close() setup(name='example1', |
