Also added test cases for the unnamed temporary destruction that is throwing assertions in Python 3.5.
14 lines
319 B
Python
14 lines
319 B
Python
import python_destructor_exception
|
|
from StringIO import StringIO
|
|
import sys
|
|
|
|
#buffer = StringIO()
|
|
#sys.stderr = buffer
|
|
|
|
attributeErrorOccurred = False
|
|
try:
|
|
python_destructor_exception.ClassWithThrowingDestructor().GetBlah()
|
|
except AttributeError, e:
|
|
attributeErrorOccurred = True
|
|
|
|
assert attributeErrorOccurred
|