Back to index

python3.2  3.2.2
Public Member Functions
test.test_isinstance.TestIsSubclassExceptions Class Reference

List of all members.

Public Member Functions

def test_dont_mask_non_attribute_error
def test_mask_attribute_error
def test_dont_mask_non_attribute_error_in_cls_arg
def test_mask_attribute_error_in_cls_arg

Detailed Description

Definition at line 103 of file test_isinstance.py.


Member Function Documentation

Definition at line 104 of file test_isinstance.py.

00104 
00105     def test_dont_mask_non_attribute_error(self):
00106         class C(object):
00107             def getbases(self):
00108                 raise RuntimeError
00109             __bases__ = property(getbases)
00110 
00111         class S(C): pass
00112 
00113         self.assertRaises(RuntimeError, issubclass, C(), S())

Here is the call graph for this function:

Definition at line 128 of file test_isinstance.py.

00128 
00129     def test_dont_mask_non_attribute_error_in_cls_arg(self):
00130         class B: pass
00131 
00132         class C(object):
00133             def getbases(self):
00134                 raise RuntimeError
00135             __bases__ = property(getbases)
00136 
00137         self.assertRaises(RuntimeError, issubclass, B, C())

Here is the call graph for this function:

Definition at line 114 of file test_isinstance.py.

00114 
00115     def test_mask_attribute_error(self):
00116         class C(object):
00117             def getbases(self):
00118                 raise AttributeError
00119             __bases__ = property(getbases)
00120 
00121         class S(C): pass
00122 
00123         self.assertRaises(TypeError, issubclass, C(), S())

Here is the call graph for this function:

Definition at line 138 of file test_isinstance.py.

00138 
00139     def test_mask_attribute_error_in_cls_arg(self):
00140         class B: pass
00141 
00142         class C(object):
00143             def getbases(self):
00144                 raise AttributeError
00145             __bases__ = property(getbases)
00146 
00147         self.assertRaises(TypeError, issubclass, B, C())
00148 
00149 
00150 
# meta classes for creating abstract classes and instances

Here is the call graph for this function:


The documentation for this class was generated from the following file: