Author: Matti Picus <[email protected]>
Branch: numpypy-ellipse-indexing
Changeset: r64059:8f5b4f1c5864
Date: 2013-05-13 23:45 +0300
http://bitbucket.org/pypy/pypy/changeset/8f5b4f1c5864/
Log: a failing test
diff --git a/pypy/module/micronumpy/test/test_numarray.py
b/pypy/module/micronumpy/test/test_numarray.py
--- a/pypy/module/micronumpy/test/test_numarray.py
+++ b/pypy/module/micronumpy/test/test_numarray.py
@@ -1634,7 +1634,7 @@
assert (zeros(1)[[]] == []).all()
def test_int_array_index_setitem(self):
- from numpypy import arange, zeros, array
+ from numpypy import arange, zeros
a = arange(10)
a[[3, 2, 1, 5]] = zeros(4, dtype=int)
assert (a == [0, 0, 0, 0, 4, 0, 6, 7, 8, 9]).all()
@@ -1661,6 +1661,12 @@
assert (b == [20, 1, 21, 3, 4]).all()
raises(ValueError, "array([1, 2])[array([True, False, True])] = [1, 2,
3]")
+ def test_ellipse_index_setitem(self):
+ from numpypy import arange
+ b = arange(5)
+ b[...] = 100
+ assert (b == 100).all()
+
def test_weakref(self):
import _weakref
from numpypy import array
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit