diff options
author | Georg Brandl <georg@python.org> | 2007-08-21 06:03:43 (GMT) |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2007-08-21 06:03:43 (GMT) |
commit | d7e9f608c33264f151264eb604bbcfdafe8c7a02 (patch) | |
tree | d59e1b1eb61db9589f2b27e5fa84ab93b80834a8 /Lib/test | |
parent | fdca6d8599e46ee7fc7844a798666fc60923fbe5 (diff) | |
download | cpython-d7e9f608c33264f151264eb604bbcfdafe8c7a02.zip cpython-d7e9f608c33264f151264eb604bbcfdafe8c7a02.tar.gz cpython-d7e9f608c33264f151264eb604bbcfdafe8c7a02.tar.bz2 |
Revert accidental checkins from last commit.
Diffstat (limited to 'Lib/test')
-rw-r--r-- | Lib/test/test_exceptions.py | 17 |
1 files changed, 1 insertions, 16 deletions
diff --git a/Lib/test/test_exceptions.py b/Lib/test/test_exceptions.py index 2f57f3d..657cbc5 100644 --- a/Lib/test/test_exceptions.py +++ b/Lib/test/test_exceptions.py @@ -9,16 +9,6 @@ from test.test_support import (TESTFN, unlink, run_unittest, catch_warning) from test.test_pep352 import ignore_message_warning -class NaiveException(Exception): - def __init__(self, x): - self.x = x - -class SomewhatNaiveException(Exception): - def __init__(self, x): - self.x = x - Exception.__init__(self) - - # XXX This is not really enough, each *operation* should be tested! class ExceptionTests(unittest.TestCase): @@ -273,10 +263,6 @@ class ExceptionTests(unittest.TestCase): {'message' : '', 'args' : (u'\u3042', 0, 1, 'ouch'), 'object' : u'\u3042', 'reason' : 'ouch', 'start' : 0, 'end' : 1}), - (NaiveException, ('foo',), - {'message': '', 'args': ('foo',), 'x': 'foo'}), - (SomewhatNaiveException, ('foo',), - {'message': '', 'args': (), 'x': 'foo'}), ] try: exceptionList.append( @@ -297,8 +283,7 @@ class ExceptionTests(unittest.TestCase): if type(e) is not exc: raise # Verify module name - if not type(e).__name__.endswith('NaiveException'): - self.assertEquals(type(e).__module__, 'exceptions') + self.assertEquals(type(e).__module__, 'exceptions') # Verify no ref leaks in Exc_str() s = str(e) for checkArgName in expected: |