diff options
| author | Georg Brandl <georg@python.org> | 2008-03-21 20:11:46 (GMT) |
|---|---|---|
| committer | Georg Brandl <georg@python.org> | 2008-03-21 20:11:46 (GMT) |
| commit | 5a44424c5e6b9533b12773fadeaf436903ca855e (patch) | |
| tree | 798911139fbccc6a8574ed0e13388affea097082 /Lib/test | |
| parent | 77354cf5ef9644121a28041216591762628d8b65 (diff) | |
| download | cpython-5a44424c5e6b9533b12773fadeaf436903ca855e.zip cpython-5a44424c5e6b9533b12773fadeaf436903ca855e.tar.gz cpython-5a44424c5e6b9533b12773fadeaf436903ca855e.tar.bz2 | |
#2358: add py3k warning to sys.exc_clear().
Diffstat (limited to 'Lib/test')
| -rw-r--r-- | Lib/test/test_py3kwarn.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Lib/test/test_py3kwarn.py b/Lib/test/test_py3kwarn.py index 2b54ee1..aaa1623 100644 --- a/Lib/test/test_py3kwarn.py +++ b/Lib/test/test_py3kwarn.py @@ -94,6 +94,11 @@ class TestPy3KWarnings(unittest.TestCase): with catch_warning() as w: self.assertWarning(sorted(lst, cmp), w, expected) + def test_sys_exc_clear(self): + expected = 'sys.exc_clear() not supported in 3.x. Use except clauses.' + with catch_warning() as w: + self.assertWarning(sys.exc_clear(), w, expected) + def test_main(): run_unittest(TestPy3KWarnings) |
