churchyard / rpms / python2

Forked from rpms/python2 6 years ago
Clone
866e929
diff -up Python-2.7.2/Lib/distutils/tests/test_build_ext.py.mark-tests-that-fail-in-rpmbuild Python-2.7.2/Lib/distutils/tests/test_build_ext.py
866e929
--- Python-2.7.2/Lib/distutils/tests/test_build_ext.py.mark-tests-that-fail-in-rpmbuild	2011-09-08 16:07:25.033834312 -0400
866e929
+++ Python-2.7.2/Lib/distutils/tests/test_build_ext.py	2011-09-08 17:43:15.656441082 -0400
866e929
@@ -330,6 +332,7 @@ class BuildExtTestCase(support.TempdirMa
866e929
         self.assertEqual(lastdir, 'bar')
866e929
 
866e929
     def test_ext_fullpath(self):
866e929
+        debug_ext = sysconfig.get_config_var("DEBUG_EXT")
866e929
         ext = sysconfig.get_config_vars()['SO']
866e929
         dist = Distribution()
866e929
         cmd = build_ext(dist)
866e929
@@ -337,14 +340,14 @@ class BuildExtTestCase(support.TempdirMa
866e929
         cmd.distribution.package_dir = {'': 'src'}
866e929
         cmd.distribution.packages = ['lxml', 'lxml.html']
866e929
         curdir = os.getcwd()
866e929
-        wanted = os.path.join(curdir, 'src', 'lxml', 'etree' + ext)
866e929
+        wanted = os.path.join(curdir, 'src', 'lxml', 'etree' + debug_ext + ext)
866e929
         path = cmd.get_ext_fullpath('lxml.etree')
866e929
         self.assertEqual(wanted, path)
866e929
 
866e929
         # building lxml.etree not inplace
866e929
         cmd.inplace = 0
866e929
         cmd.build_lib = os.path.join(curdir, 'tmpdir')
866e929
-        wanted = os.path.join(curdir, 'tmpdir', 'lxml', 'etree' + ext)
866e929
+        wanted = os.path.join(curdir, 'tmpdir', 'lxml', 'etree' + debug_ext + ext)
866e929
         path = cmd.get_ext_fullpath('lxml.etree')
866e929
         self.assertEqual(wanted, path)
866e929
 
866e929
@@ -354,13 +357,13 @@ class BuildExtTestCase(support.TempdirMa
866e929
         cmd.distribution.packages = ['twisted', 'twisted.runner.portmap']
866e929
         path = cmd.get_ext_fullpath('twisted.runner.portmap')
866e929
         wanted = os.path.join(curdir, 'tmpdir', 'twisted', 'runner',
866e929
-                              'portmap' + ext)
866e929
+                              'portmap' + debug_ext + ext)
866e929
         self.assertEqual(wanted, path)
866e929
 
866e929
         # building twisted.runner.portmap inplace
866e929
         cmd.inplace = 1
866e929
         path = cmd.get_ext_fullpath('twisted.runner.portmap')
866e929
-        wanted = os.path.join(curdir, 'twisted', 'runner', 'portmap' + ext)
866e929
+        wanted = os.path.join(curdir, 'twisted', 'runner', 'portmap' + debug_ext + ext)
866e929
         self.assertEqual(wanted, path)
866e929
 
866e929
     def test_build_ext_inplace(self):
866e929
@@ -373,8 +376,9 @@ class BuildExtTestCase(support.TempdirMa
866e929
         cmd.distribution.package_dir = {'': 'src'}
866e929
         cmd.distribution.packages = ['lxml', 'lxml.html']
866e929
         curdir = os.getcwd()
866e929
+        debug_ext = sysconfig.get_config_var("DEBUG_EXT")
866e929
         ext = sysconfig.get_config_var("SO")
866e929
-        wanted = os.path.join(curdir, 'src', 'lxml', 'etree' + ext)
866e929
+        wanted = os.path.join(curdir, 'src', 'lxml', 'etree' + debug_ext + ext)
866e929
         path = cmd.get_ext_fullpath('lxml.etree')
866e929
         self.assertEqual(wanted, path)
866e929
 
866e929
@@ -412,10 +416,11 @@ class BuildExtTestCase(support.TempdirMa
866e929
         dist = Distribution({'name': 'UpdateManager'})
866e929
         cmd = build_ext(dist)
866e929
         cmd.ensure_finalized()
866e929
+        debug_ext = sysconfig.get_config_var("DEBUG_EXT")
866e929
         ext = sysconfig.get_config_var("SO")
866e929
         ext_name = os.path.join('UpdateManager', 'fdsend')
866e929
         ext_path = cmd.get_ext_fullpath(ext_name)
866e929
-        wanted = os.path.join(cmd.build_lib, 'UpdateManager', 'fdsend' + ext)
866e929
+        wanted = os.path.join(cmd.build_lib, 'UpdateManager', 'fdsend' + debug_ext + ext)
866e929
         self.assertEqual(ext_path, wanted)
866e929
 
Matej Stuchlik ebcba88
     @unittest.skipUnless(sys.platform == 'win32', 'these tests require Windows')