Exceptions should inherit from Exception now.

This commit is contained in:
Neal Norwitz 2006-03-24 07:03:44 +00:00
parent 7fbb9d1174
commit 5a822fb720

View file

@ -211,7 +211,7 @@ class MiscTest(unittest.TestCase):
# Check that exceptions in __nonzero__ are properly # Check that exceptions in __nonzero__ are properly
# propagated by the not operator # propagated by the not operator
import operator import operator
class Exc: class Exc(Exception):
pass pass
class Bad: class Bad:
def __nonzero__(self): def __nonzero__(self):
@ -305,7 +305,7 @@ class ListTest(unittest.TestCase):
def test_badentry(self): def test_badentry(self):
# make sure that exceptions for item comparison are properly # make sure that exceptions for item comparison are properly
# propagated in list comparisons # propagated in list comparisons
class Exc: class Exc(Exception):
pass pass
class Bad: class Bad:
def __eq__(self, other): def __eq__(self, other):