]> granicus.if.org Git - python/commitdiff
Revert 60793 for test_array; on a 64-bit system,
authorMartin v. Löwis <martin@v.loewis.de>
Fri, 15 Feb 2008 19:52:38 +0000 (19:52 +0000)
committerMartin v. Löwis <martin@v.loewis.de>
Fri, 15 Feb 2008 19:52:38 +0000 (19:52 +0000)
MemoryError was not guaranteed.

Lib/test/test_array.py
Misc/NEWS

index a665bacc25f2de772a5af3c615727590fc71d212..597f3b24219556185f2a11bc2544e1cd30695d5b 100755 (executable)
@@ -975,23 +975,6 @@ tests.append(FloatTest)
 class DoubleTest(FPTest):
     typecode = 'd'
     minitemsize = 8
-
-    def test_alloc_overflow(self):
-        a = array.array('d', [-1]*65536)
-        try:
-            a *= 65536
-        except MemoryError:
-            pass
-        else:
-            self.fail("a *= 2**16 didn't raise MemoryError")
-        b = array.array('d', [ 2.71828183, 3.14159265, -1])
-        try:
-            b * 1431655766
-        except MemoryError:
-            pass
-        else:
-            self.fail("a * 1431655766 didn't raise MemoryError")
-
 tests.append(DoubleTest)
 
 def test_main(verbose=None):
index d5efce7bdbd017d845d0ac7fd355e9a30c238684..ac96e2117ff3cdbc8d121b1d1b6137a94f922520 100644 (file)
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -13,6 +13,7 @@ Extension Modules
 -----------------
 
 - Fix deallocation of array objects when allocation ran out of memory.
+  Remove array test case that was incorrect on 64-bit systems.
 
 
 What's New in Python 2.5.2c1?