diff options
author | Facundo Batista <facundobatista@gmail.com> | 2008-03-22 02:45:37 (GMT) |
---|---|---|
committer | Facundo Batista <facundobatista@gmail.com> | 2008-03-22 02:45:37 (GMT) |
commit | 6415667fe20b90685f85948e980215d44b4696ac (patch) | |
tree | 8d580477ac6ea4cad03615932923d5eaed65acfa /Lib | |
parent | 3e838dd88df53b47acf5e817c8ec375d430ca056 (diff) | |
download | cpython-6415667fe20b90685f85948e980215d44b4696ac.zip cpython-6415667fe20b90685f85948e980215d44b4696ac.tar.gz cpython-6415667fe20b90685f85948e980215d44b4696ac.tar.bz2 |
Small fix that complicated the test actually when that
test failed.
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/test/test_decimal.py | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/Lib/test/test_decimal.py b/Lib/test/test_decimal.py index 5e69b64..5e53318 100644 --- a/Lib/test/test_decimal.py +++ b/Lib/test/test_decimal.py @@ -949,21 +949,27 @@ class DecimalArithmeticOperatorsTest(unittest.TestCase): def thfunc1(cls): d1 = Decimal(1) d3 = Decimal(3) - cls.assertEqual(d1/d3, Decimal('0.333333333')) + test1 = d1/d3 cls.synchro.wait() - cls.assertEqual(d1/d3, Decimal('0.333333333')) + test2 = d1/d3 cls.finish1.set() + + cls.assertEqual(test1, Decimal('0.333333333')) + cls.assertEqual(test2, Decimal('0.333333333')) return def thfunc2(cls): d1 = Decimal(1) d3 = Decimal(3) - cls.assertEqual(d1/d3, Decimal('0.333333333')) + test1 = d1/d3 thiscontext = getcontext() thiscontext.prec = 18 - cls.assertEqual(d1/d3, Decimal('0.333333333333333333')) + test2 = d1/d3 cls.synchro.set() cls.finish2.set() + + cls.assertEqual(test1, Decimal('0.333333333')) + cls.assertEqual(test2, Decimal('0.333333333333333333')) return |