diff options
author | Nick Coghlan <ncoghlan@gmail.com> | 2006-08-31 12:51:25 (GMT) |
---|---|---|
committer | Nick Coghlan <ncoghlan@gmail.com> | 2006-08-31 12:51:25 (GMT) |
commit | db38588a2549035e0e4bd7b7a3627ab48addb2bd (patch) | |
tree | 702df06fb020295ef5d7d8a26ca9ad79aeabfcca /Lib | |
parent | 8b6999b4c5fab174090be263ba90f193bdede141 (diff) | |
download | cpython-db38588a2549035e0e4bd7b7a3627ab48addb2bd.zip cpython-db38588a2549035e0e4bd7b7a3627ab48addb2bd.tar.gz cpython-db38588a2549035e0e4bd7b7a3627ab48addb2bd.tar.bz2 |
Remove the old decimal context management tests from test_contextlib (guess who didn't run the test suite before committing...)
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/test/test_contextlib.py | 26 |
1 files changed, 0 insertions, 26 deletions
diff --git a/Lib/test/test_contextlib.py b/Lib/test/test_contextlib.py index 2cf39ae..747785d 100644 --- a/Lib/test/test_contextlib.py +++ b/Lib/test/test_contextlib.py @@ -330,32 +330,6 @@ class LockContextTestCase(unittest.TestCase): return True self.boilerPlate(lock, locked) -class DecimalContextTestCase(unittest.TestCase): - - # XXX Somebody should write more thorough tests for this - - def testBasic(self): - ctx = decimal.getcontext() - orig_context = ctx.copy() - try: - ctx.prec = save_prec = decimal.ExtendedContext.prec + 5 - with decimal.ExtendedContext.get_manager(): - self.assertEqual(decimal.getcontext().prec, - decimal.ExtendedContext.prec) - self.assertEqual(decimal.getcontext().prec, save_prec) - try: - with decimal.ExtendedContext.get_manager(): - self.assertEqual(decimal.getcontext().prec, - decimal.ExtendedContext.prec) - 1/0 - except ZeroDivisionError: - self.assertEqual(decimal.getcontext().prec, save_prec) - else: - self.fail("Didn't raise ZeroDivisionError") - finally: - decimal.setcontext(orig_context) - - # This is needed to make the test actually run under regrtest.py! def test_main(): run_suite( |