]> granicus.if.org Git - python/commitdiff
A quick fix that removes a spurious unittest failure when users
authorRonald Oussoren <ronaldoussoren@mac.com>
Tue, 19 Feb 2008 15:29:40 +0000 (15:29 +0000)
committerRonald Oussoren <ronaldoussoren@mac.com>
Tue, 19 Feb 2008 15:29:40 +0000 (15:29 +0000)
upgrade their python2.5 install and then run Python's test suite.
This is needed because one of the test files for the decimal module
changed it name (see issue 2114) and OSX doesn't feature a full
package manager.

Mac/BuildScript/build-installer.py

index 7ffb065897d0f35e7610f93d2c58dcba24d6be2a..ae394bb722850c6516ea53c129fcb7179beeeab7 100755 (executable)
@@ -733,6 +733,16 @@ def buildPython():
         os.symlink(os.path.join(to_framework, fn),
                    os.path.join(usr_local_bin, fn))
 
+    # A quick fix that removes a spurious unittest failure when users
+    # upgrade their python2.5 install and then run Python's test suite.
+    # This is needed because one of the test files for the decimal module
+    # changed it name (see issue 2114).
+    test_dir = os.path.join(rootDir, 'Library', 'Frameworks',
+            'Python.framework', 'Versions', version, 'lib',
+            'python%s'%(version,), 'test', 'decimaltestdata')
+    data = open(os.path.join(test_dir, 'reduce.decTest'), 'r').read()
+    open(os.path.join(test_dir, 'normalize.decTest'), 'w').write(data)
+
     os.chdir(curdir)