[Python-checkins] r80091 - python/branches/signalfd-issue8407/Lib/test/test_inspect.py

jean-paul.calderone python-checkins at python.org
Thu Apr 15 07:07:30 CEST 2010


Author: jean-paul.calderone
Date: Thu Apr 15 07:07:30 2010
New Revision: 80091

Log:
Back this out, unrelated.

Modified:
   python/branches/signalfd-issue8407/Lib/test/test_inspect.py

Modified: python/branches/signalfd-issue8407/Lib/test/test_inspect.py
==============================================================================
--- python/branches/signalfd-issue8407/Lib/test/test_inspect.py	(original)
+++ python/branches/signalfd-issue8407/Lib/test/test_inspect.py	Thu Apr 15 07:07:30 2010
@@ -372,24 +372,10 @@
         self.assertRaises(IOError, inspect.getsource, unicodedata)
         self.assertRaises(IOError, inspect.findsource, unicodedata)
 
-
-
-class _BrokenDescriptor(object):
-    """
-    A descriptor which raises an exception when it is accessed as an attribute
-    of the class it is on.  This is used to test inspect's handling of such
-    descriptors.
-    """
-    def __get__(self, *args):
-        raise RuntimeError("This descriptor cannot be gotten.")
-
-
-
 # Helper for testing classify_class_attrs.
 def attrs_wo_objs(cls):
     return [t[:3] for t in inspect.classify_class_attrs(cls)]
 
-
 class TestClassesAndFunctions(unittest.TestCase):
     def test_classic_mro(self):
         # Test classic-class method resolution order.
@@ -476,8 +462,6 @@
 
             datablob = '1'
 
-            broken_data = _BrokenDescriptor()
-
         attrs = attrs_wo_objs(A)
         self.assertIn(('s', 'static method', A), attrs, 'missing static method')
         self.assertIn(('c', 'class method', A), attrs, 'missing class method')


More information about the Python-checkins mailing list