[pypy-commit] pypy numpypy-ellipse-indexing: a failing test
mattip
noreply at buildbot.pypy.org
Tue May 14 10:17:56 CEST 2013
Author: Matti Picus <matti.picus at gmail.com>
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
More information about the pypy-commit
mailing list