Author: Maciej Fijalkowski <[email protected]>
Branch: numpy-multidim
Changeset: r48532:57661ae58454
Date: 2011-10-27 19:40 +0200
http://bitbucket.org/pypy/pypy/changeset/57661ae58454/

Log:    creation from sequences

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
@@ -680,6 +680,12 @@
         a[1] = [1, 2, 3, 4]
         assert a[1, 2] == 3
         raises(TypeError, a[1].__setitem__, [1, 2, 3])
+        a = numpy.array([[1, 2], [3, 4]])
+        assert a == [[1, 2], [3, 4]]
+        a[1] = numpy.array([5, 6])
+        assert a == [[1, 2], [5, 6]]
+        a[:,1] = numpy.array([8, 10])
+        assert a == [[1, 8], [5, 10]]
 
 class AppTestSupport(object):
     def setup_class(cls):
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to