diff options
author | Ronald Oussoren <ronaldoussoren@mac.com> | 2010-01-17 18:52:29 (GMT) |
---|---|---|
committer | Ronald Oussoren <ronaldoussoren@mac.com> | 2010-01-17 18:52:29 (GMT) |
commit | 93492334df7e664d1eb1cc02ac206b0bee686568 (patch) | |
tree | 2c11d401cb2bcb5d830e39b2dd091659de179789 /Lib | |
parent | 9a426c302fbad355697d870fc102811ec2a3d614 (diff) | |
download | cpython-93492334df7e664d1eb1cc02ac206b0bee686568.zip cpython-93492334df7e664d1eb1cc02ac206b0bee686568.tar.gz cpython-93492334df7e664d1eb1cc02ac206b0bee686568.tar.bz2 |
Ensure that distutils.tests.test_util will pass in 64-bit builds.
Fixes #7591
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/distutils/tests/test_util.py | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/Lib/distutils/tests/test_util.py b/Lib/distutils/tests/test_util.py index dcc1a20..0c732f8 100644 --- a/Lib/distutils/tests/test_util.py +++ b/Lib/distutils/tests/test_util.py @@ -96,7 +96,12 @@ class UtilTestCase(support.EnvironGuard, unittest.TestCase): get_config_vars()['CFLAGS'] = ('-fno-strict-aliasing -DNDEBUG -g ' '-fwrapv -O3 -Wall -Wstrict-prototypes') - self.assertEquals(get_platform(), 'macosx-10.3-i386') + cursize = sys.maxsize + sys.maxsize = (2 ** 31)-1 + try: + self.assertEquals(get_platform(), 'macosx-10.3-i386') + finally: + sys.maxsize = cursize # macbook with fat binaries (fat, universal or fat64) os.environ['MACOSX_DEPLOYMENT_TARGET'] = '10.4' |