[Numpy-svn] r3335 - trunk/numpy/core/tests

numpy-svn at scipy.org numpy-svn at scipy.org
Fri Oct 13 19:09:46 CDT 2006


Author: stefan
Date: 2006-10-13 19:09:29 -0500 (Fri, 13 Oct 2006)
New Revision: 3335

Modified:
   trunk/numpy/core/tests/test_regression.py
Log:
Add tests for tickets #335, #341, #342 and #344.


Modified: trunk/numpy/core/tests/test_regression.py
===================================================================
--- trunk/numpy/core/tests/test_regression.py	2006-10-13 20:50:00 UTC (rev 3334)
+++ trunk/numpy/core/tests/test_regression.py	2006-10-14 00:09:29 UTC (rev 3335)
@@ -506,5 +506,24 @@
         """Ticket #334"""
         assert N.dtype('i4') == N.dtype(('i4',()))
         
+    def check_dtype_posttuple(self, level=rlevel):
+        """Ticket #335"""
+        N.dtype([('col1', '()i4')])
+        
+    def check_numeric_carray_compare(self, level=rlevel):
+        """Ticket #341"""
+        assert_equal(N.array([ 'X' ], 'c'),'X')        
+        
+    def check_string_array_size(self, level=rlevel):
+        """Ticket #342"""
+        self.failUnlessRaises(ValueError,
+                              N.array,[['X'],['X','X','X']],'|S1')
+                              
+    def check_dtype_repr(self, level=rlevel):
+        """Ticket #344"""
+        dt1=N.dtype(('uint32', 2))
+        dt2=N.dtype(('uint32', (2,)))        
+        assert_equal(dt1.__repr__(), dt2.__repr__())
+                
 if __name__ == "__main__":
     NumpyTest().run()



More information about the Numpy-svn mailing list