Author: Vincent Legoll <[email protected]>
Branch: fix-1674
Changeset: r81486:0c6658a532bc
Date: 2015-12-28 12:40 +0100
http://bitbucket.org/pypy/pypy/changeset/0c6658a532bc/
Log: Add a failing test for issue 1717
diff --git a/pypy/module/micronumpy/test/test_ndarray.py
b/pypy/module/micronumpy/test/test_ndarray.py
--- a/pypy/module/micronumpy/test/test_ndarray.py
+++ b/pypy/module/micronumpy/test/test_ndarray.py
@@ -3321,6 +3321,13 @@
columns = array([0, 2])
assert (x[rows[:, newaxis], columns] == array([[ 3, 5], [ 9,
11]])).all()
+ def test_issue_1717(self):
+ from numpy import array
+ a = array((1, 5)).reshape(2,1)
+ assert (a == array([[1], [5]])).all()
+ a[0, array([True], dtype=bool)] = 100
+ assert (a == array([[100], [5]])).all()
+
def test_ravel(self):
from numpy import arange
assert (arange(3).ravel() == arange(3)).all()
_______________________________________________
pypy-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-commit